diff --git a/resources/views/form/rapport-iva/1714829109-b695430a-48aa-424e-9e50-6704e933380c.blade.php b/resources/views/form/rapport-iva/1714829109-b695430a-48aa-424e-9e50-6704e933380c.blade.php index 601eb343..d98edd08 100644 --- a/resources/views/form/rapport-iva/1714829109-b695430a-48aa-424e-9e50-6704e933380c.blade.php +++ b/resources/views/form/rapport-iva/1714829109-b695430a-48aa-424e-9e50-6704e933380c.blade.php @@ -86,9 +86,25 @@ @case('dropdown') @if($id && $question->code == 'select_brandsku') @@ -219,7 +235,7 @@ $('#field-contact_id').append($("").attr("value", '').text('-- Select --')); for(let itm of data) { //$('#field-contact_id').append($("").attr("value",itm.value).text(itm.display)); - $('#field-contact_id').append($("").attr("ciscure_dr_tagging", itm.contact.ciscure_dr_tagging).attr("emprogest_gel_dr_tagging", itm.contact.emprogest_gel_dr_tagging).attr("dydroeva_dr_tagging", itm.contact.dydroeva_dr_tagging).attr("depot_dr_tagging", itm.contact.depot_dr_tagging).attr("materna_hcg_dr_tagging", itm.contact.materna_hcg_dr_tagging).attr("materna_hmg_dr_tagging", itm.contact.materna_hmg_dr_tagging).attr("value", itm.value).text(itm.display)); + $('#field-contact_id').append($("").attr("ciscure_dr_tagging", itm.contact.ciscure_dr_tagging).attr("emprogest_gel_dr_tagging", itm.contact.emprogest_gel_dr_tagging).attr("dydroeva_dr_tagging", itm.contact.dydroeva_dr_tagging).attr("depot_dr_tagging", itm.contact.depot_dr_tagging).attr("materna_hcg_dr_tagging", itm.contact.materna_hcg_dr_tagging).attr("materna_hmg_dr_tagging", itm.contact.materna_hmg_dr_tagging).attr("value", itm.value).attr("sbu_code", itm.contact.msl_code).attr("uid", itm.contact.uid_number).text(itm.display)); } $('#field-contact_id').unbind() @@ -301,6 +317,14 @@ }) + + $('#field-contact_id').change(function() { + $('#field-sbu_code').val($('option:selected', this).attr('sbu_code')); + }) + + $('#field-contact_id').change(function() { + $('#field-uid').val($('option:selected', this).attr('uid')); + }) } @@ -326,6 +350,7 @@ $('#field-enter_investment_amount').attr("min",0); + $('#field-select_brandsku').on('change',function(){ let value=$('#field-select_brandsku').val().trim(); if(value===''){ @@ -355,6 +380,12 @@ } }) + + + + $('#field-sbu_code').prop('readonly', true); + $('#field-uid').prop('readonly', true); + $('#report-form').on('submit', function(event) { event.preventDefault(); $("#pageloader").fadeIn();