mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-23 20:12:53 +08:00
删除险种时,删除两全时,(被保险人)国富人寿附加豁免保险费重大疾病保险(B款)一并删除
This commit is contained in:
@@ -1588,8 +1588,10 @@ export default {
|
||||
className: 'dialog-delete'
|
||||
})
|
||||
.then(() => {
|
||||
let currentGFRS_A0011
|
||||
if (this.chooseProducts[index].isMainRisk == 0) {
|
||||
this.chooseProducts = []
|
||||
localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
this.$jump({
|
||||
flag: 'goBack',
|
||||
extra: {
|
||||
@@ -1604,9 +1606,9 @@ export default {
|
||||
})
|
||||
localStorage.trialList = ''
|
||||
}else{
|
||||
currentGFRS_A0011 = this.chooseProducts[index].productCode == 'GFRS_A0011'?true:false //当前删除的是否是两全
|
||||
this.chooseProducts.splice(index, 1)
|
||||
}
|
||||
|
||||
if (
|
||||
this.chooseProducts[0].mainRiskCode == 'GFRS_M0051' ||
|
||||
this.chooseProducts[0].mainRiskCode == 'GFRS_M0044' ||
|
||||
@@ -1614,53 +1616,54 @@ export default {
|
||||
this.chooseProducts[0].mainRiskCode == 'GFRS_M0038' ||
|
||||
this.chooseProducts[0].mainRiskCode == 'GFRS_M0040'
|
||||
) {
|
||||
let risks = this.chooseProducts
|
||||
let longRisks = []
|
||||
//拿到长险附加险数组
|
||||
for (let i = 1; i < risks.length; i++) {
|
||||
for (let j = 0; j < risks[i].calFactorLst.length; j++) {
|
||||
if (risks[i].calFactorLst[j].code === 'insuYear') {
|
||||
if (
|
||||
((risks[i].calFactorLst[j].insuYearFlag == 'Y' && risks[i].calFactorLst[j].insuYear > 1) || risks[i].calFactorLst[j].insuYearFlag == 'A') &&
|
||||
risks[i].productCode != 'GFRS_A0010'
|
||||
) {
|
||||
longRisks.push(risks[i].productCode)
|
||||
if (currentGFRS_A0011 && JSON.stringify(this.chooseProducts).includes('GFRS_A0010')) {
|
||||
this.chooseProducts.forEach((item, index01) => {
|
||||
if(item.productCode == 'GFRS_A0010'){
|
||||
this.chooseProducts.splice(index01, 1)
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (
|
||||
(this.chooseProducts.length == 2 && this.chooseProducts[1].productCode == 'GFRS_A0010') ||
|
||||
(this.chooseProducts.length == 3 &&
|
||||
JSON.stringify(this.chooseProducts).includes('GFRS_A0010') &&
|
||||
JSON.stringify(this.chooseProducts).includes('GFRS_A0009')) ||
|
||||
(longRisks.length <= 0 && this.chooseProducts.length > 1)
|
||||
) {
|
||||
Dialog.alert({
|
||||
title: '提示',
|
||||
message: '当前未投保其他长险附加险,将删除该险种重新选择附加险!'
|
||||
}).then(() => {
|
||||
this.chooseProducts.splice(1, 1)
|
||||
localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
this.getTrial()
|
||||
})
|
||||
// this.$toast('当前未投保其他长险附加险,请删除该险种重新选择附加险!')
|
||||
// this.nextStepFlag = true
|
||||
}
|
||||
if (
|
||||
(this.chooseProducts.length == 3 &&
|
||||
JSON.stringify(this.chooseProducts).includes('GFRS_A0010') &&
|
||||
JSON.stringify(this.chooseProducts).includes('GFRS_A0009')) ||
|
||||
(longRisks.length <= 0 && this.chooseProducts.length > 1)
|
||||
) {
|
||||
this.$toast('当前未投保其他长险附加险,请删除该险种重新选择附加险!')
|
||||
this.nextStepFlag = true
|
||||
this.chooseProducts.splice(1, 2)
|
||||
localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
// this.getTrial()
|
||||
}
|
||||
// Dialog.alert({
|
||||
// title: '提示',
|
||||
// message: '当前未投保其他长险附加险,将删除该险种重新选择附加险!'
|
||||
// }).then(() => {
|
||||
// })
|
||||
}
|
||||
|
||||
|
||||
// let risks = this.chooseProducts
|
||||
// let longRisks = []
|
||||
// //拿到长险附加险数组
|
||||
// for (let i = 1; i < risks.length; i++) {
|
||||
// for (let j = 0; j < risks[i].calFactorLst.length; j++) {
|
||||
// if (risks[i].calFactorLst[j].code === 'insuYear') {
|
||||
// if (
|
||||
// ((risks[i].calFactorLst[j].insuYearFlag == 'Y' && risks[i].calFactorLst[j].insuYear > 1) || risks[i].calFactorLst[j].insuYearFlag == 'A') &&
|
||||
// risks[i].productCode != 'GFRS_A0010'
|
||||
// ) {
|
||||
// longRisks.push(risks[i].productCode)
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// if (
|
||||
// (this.chooseProducts.length == 2 && this.chooseProducts[1].productCode == 'GFRS_A0010') ||
|
||||
// (this.chooseProducts.length == 3 &&
|
||||
// JSON.stringify(this.chooseProducts).includes('GFRS_A0010') &&
|
||||
// JSON.stringify(this.chooseProducts).includes('GFRS_A0009')) ||
|
||||
// (longRisks.length <= 0 && this.chooseProducts.length > 1)
|
||||
// ) {
|
||||
// Dialog.alert({
|
||||
// title: '提示',
|
||||
// message: '当前未投保其他长险附加险,将删除该险种重新选择附加险!'
|
||||
// }).then(() => {
|
||||
// this.chooseProducts.splice(1, 1)
|
||||
// localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
// this.getTrial()
|
||||
// })
|
||||
// // this.$toast('当前未投保其他长险附加险,请删除该险种重新选择附加险!')
|
||||
// // this.nextStepFlag = true
|
||||
// }
|
||||
}
|
||||
localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
this.getTrial()
|
||||
})
|
||||
@@ -1812,10 +1815,8 @@ export default {
|
||||
this.$toast('当前未投保其他长险附加险,请删除该险种重新选择附加险!')
|
||||
this.nextStepFlag = true
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
this.againGetTrial()
|
||||
// this.againGetTrial()
|
||||
} else {
|
||||
this.nextStepFlag = true
|
||||
this.$toast(resultData.resultMessage)
|
||||
|
||||
Reference in New Issue
Block a user