mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-10 04:36:44 +08:00
Merge remote-tracking branch 'origin/dev' into dev
This commit is contained in:
@@ -252,6 +252,42 @@ export default {
|
||||
isRemit: resultData.productTrialInfoDTO.isRemit,
|
||||
remitType: resultData.productTrialInfoDTO.remitType
|
||||
}
|
||||
/******八桂D中介渠道校验短险规则*******/
|
||||
let risks = JSON.parse(localStorage.chooseProducts);
|
||||
let checkRisk = true;
|
||||
if(risks[0].productCode =="GFRS_M0051"||risks[0].productCode == 'GFRS_M0044') {
|
||||
if(this.result.productCode=="GFRS_A0010"){
|
||||
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_A0009') {
|
||||
checkRisk=false;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if(checkRisk){
|
||||
this.$toast('当前未投保其他长险附加险,不可附加该险种!')
|
||||
return true
|
||||
}
|
||||
}
|
||||
}
|
||||
/*"let risks = JSON.parse(localStorage.chooseProducts);",
|
||||
"let checkRisk = true;",
|
||||
"for (let i = 1; i < risks.length; i++) {",
|
||||
"for(let j = 0; j < risks.calFactorLst.length; j++){",
|
||||
"if (risks.calFactorLst[j].code === \"insuYear\") {",
|
||||
"if ((risks.calFactorLst[j].insuYearFlag == \"Y\" && risks.calFactorLst[j].insuYear > 1) || risks.calFactorLst[j].insuYearFlag == \"A\") {",
|
||||
"checkRisk=false;",
|
||||
"}",
|
||||
"}",
|
||||
"}",
|
||||
"}",
|
||||
"if(checkRisk){",
|
||||
"return \"当前未投保其他长险附加险,不可附加该险种!\";",
|
||||
"}",*/
|
||||
|
||||
//构建险种数组
|
||||
let productsData
|
||||
if (localStorage.chooseProducts) {
|
||||
|
||||
@@ -1434,21 +1434,47 @@ export default {
|
||||
} else {
|
||||
this.chooseProducts.splice(index, 1)
|
||||
}
|
||||
|
||||
if(this.chooseProducts.length==2&&this.chooseProducts[1].productCode=='GFRS_A0010'){
|
||||
Dialog.alert({
|
||||
title: '提示',
|
||||
message: '当前未投保其他长险附加险,将删除该险种重新选择附加险!'
|
||||
}).then(() => {
|
||||
this.chooseProducts.splice(1, 1)
|
||||
if ( this.chooseProducts[0].mainRiskCode == 'GFRS_M0051'||this.chooseProducts[0].mainRiskCode == 'GFRS_M0044'){
|
||||
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
|
||||
}
|
||||
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()
|
||||
}
|
||||
}
|
||||
localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
this.getTrial()
|
||||
})
|
||||
// this.$toast('当前未投保其他长险附加险,请删除该险种重新选择附加险!')
|
||||
// this.nextStepFlag = true
|
||||
}
|
||||
localStorage.chooseProducts = JSON.stringify(this.chooseProducts)
|
||||
this.getTrial()
|
||||
|
||||
})
|
||||
.catch(() => {})
|
||||
},
|
||||
@@ -1557,13 +1583,25 @@ export default {
|
||||
trialInfo.duty = result
|
||||
}
|
||||
})
|
||||
//针对八桂D产品 计算被保人重疾B附加险保额 ==其他附加险的保额
|
||||
//针对八桂D产品 计算被保人重疾B附加险保额 ==其他长险附加险的保额
|
||||
if ( this.chooseProducts[0].mainRiskCode == 'GFRS_M0051'||this.chooseProducts[0].mainRiskCode == 'GFRS_M0044'){
|
||||
if(item.productCode == 'GFRS_A0010'){
|
||||
let risks = JSON.parse(localStorage.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') {
|
||||
longRisks.push(risks[i].productCode);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
let toTrial = 0
|
||||
let trials = JSON.parse(localStorage.trialList)
|
||||
trials.forEach(tr=>{
|
||||
if(tr.isMainRisk=='1'&&tr.productCode!='GFRS_A0010'){
|
||||
if(tr.isMainRisk=='1'&&tr.productCode!='GFRS_A0010'&&longRisks.includes(tr.productCode)){
|
||||
toTrial+=Number(tr.prem);
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user