diff --git a/src/views/ebiz/common/CalculatePremium.vue b/src/views/ebiz/common/CalculatePremium.vue index b93be4a43..fec29c47c 100644 --- a/src/views/ebiz/common/CalculatePremium.vue +++ b/src/views/ebiz/common/CalculatePremium.vue @@ -135,10 +135,10 @@ :max="dutyItem.maxDutyAmt" :show-plus="false" :show-minus="false" - :disabled="item.productCode == 'GFRS_A0012'" + :disabled="item.productCode == 'GFRS_A0012' || (item.productCode == 'GFRS_M0077' && !dutyItem.necess) || (item.productCode == 'GFRS_M0077' && dutyItem.duty == '311507')" class="ml10 mr10" @focus="focusStep" - @blur="blurStep(dutyItem, index)" + @blur="blurStep(dutyItem, index,item.productCode)" @change=" dutyStepperChange( item.calFactorLst[riskFactorIndex].rules[dutyItemIndex].defaultDutyAmt, @@ -1187,6 +1187,23 @@ export default { }) } } + if (validateRiskCode === 'GFRS_M0077'){ + if(dutyItem.duty == '311507' && dutyItem.necess){ + this.chooseProducts.forEach(item => { + item.calFactorLst.map((i) => { + if (i.code == 'dutyGroup') { + if(i.rules && i.rules.length != 0) { + i.rules.forEach(ii=>{ + if(ii.duty != '311507' && ii.necess){ + dutyItem.defaultDutyAmt = ii.defaultDutyAmt + } + }) + } + } + }) + }) + } + } this.valiAndSend(dutyItem, productIndex) }, valiAndSend(dutyItem, productIndex) { @@ -1216,15 +1233,31 @@ export default { focusStep() { this.nextStepFlag = true }, - blurStep(dutyItem, productIndex) { + blurStep(dutyItem, productIndex, productCode) { this.nextStepFlag = false - - //失去焦点时做验证 - if (dutyItem.necess) { - //勾选时才做验证 - this.valiAndSend(dutyItem, productIndex) - } - }, + //失去焦点时做验证 + if (dutyItem.necess) { + //勾选时才做验证 + this.valiAndSend(dutyItem, productIndex) + } + if(productCode == 'GFRS_M0077'){ + this.chooseProducts.forEach(item => { + if (item.mainRiskCode == 'GFRS_M0077') { + item.calFactorLst.map((i) => { + if (i.code == 'dutyGroup') { + if(i.rules && i.rules.length != 0) { + i.rules.forEach(ii=>{ + if(ii.duty == '311507' && ii.necess){ + ii.defaultDutyAmt = dutyItem.defaultDutyAmt + } + }) + } + } + }) + } + }) + } + }, //险种GFRS_M0016\GFRS_M0070的责任的验证规则 valiDuty(value, duty) { if (this.mainRiskCode === 'GFRS_M0016') {