FIX_EMPLOYEE_POLICY_AUTO_SELCTE_POLICY_TYPE_3 : RV
This commit is contained in:
parent
92886a8ecc
commit
eadd03c45b
@ -444,6 +444,7 @@
|
|||||||
}, 1000);
|
}, 1000);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
@ -1288,7 +1289,7 @@
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var dataId = 0;
|
||||||
$(document).ready(function() {
|
$(document).ready(function() {
|
||||||
|
|
||||||
$('#base_policy').change(function() {
|
$('#base_policy').change(function() {
|
||||||
@ -1297,9 +1298,12 @@
|
|||||||
var policy_type = $('#policy_type').val()
|
var policy_type = $('#policy_type').val()
|
||||||
console.log(client_policy_id);
|
console.log(client_policy_id);
|
||||||
|
|
||||||
var dataId = $('#policy').children('option:selected').attr('data-id');
|
dataId = $('#policy').children('option:selected').attr('data-id');
|
||||||
console.log('dataId', dataId)
|
console.log('dataId', dataId)
|
||||||
|
|
||||||
|
base_policy_data_id = $(this).children('option:selected').attr('data-id');
|
||||||
|
console.log('base_policy_data_id', base_policy_data_id);
|
||||||
|
|
||||||
var queryParams = {
|
var queryParams = {
|
||||||
client_policy_id: client_policy_id,
|
client_policy_id: client_policy_id,
|
||||||
policy_type: policy_type,
|
policy_type: policy_type,
|
||||||
@ -1348,12 +1352,18 @@
|
|||||||
|
|
||||||
$('#policy').html(policeOptionHTML);
|
$('#policy').html(policeOptionHTML);
|
||||||
|
|
||||||
if (dataId == 3) {
|
if (dataId == 3 || policy_type == 1) {
|
||||||
|
|
||||||
|
console.log('step 1')
|
||||||
|
|
||||||
setTimeout(function() {
|
setTimeout(function() {
|
||||||
|
console.log('step 2')
|
||||||
var $option = $('#policy').find('option[data-id="3"]');
|
var $option = $('#policy').find('option[data-id="3"]');
|
||||||
if ($option.length > 0) {
|
if ($option.length > 0) {
|
||||||
|
console.log('step 3')
|
||||||
$option.prop('selected', true).change();
|
$option.prop('selected', true).change();
|
||||||
} else {
|
} else {
|
||||||
|
console.log('step 4');
|
||||||
toastr.warning('The insurer does not have a GMC-Parents policy.', 'Warning');
|
toastr.warning('The insurer does not have a GMC-Parents policy.', 'Warning');
|
||||||
}
|
}
|
||||||
}, 1500);
|
}, 1500);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user