mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-07 04:16:44 +08:00
Compare commits
8 Commits
feature/【2
...
feature/GF
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
676224a7b4 | ||
|
|
ce15304cdb | ||
|
|
bd007cdccc | ||
|
|
4149903e13 | ||
|
|
e15ccaa279 | ||
|
|
5e5e660a3d | ||
|
|
dbaa918f30 | ||
|
|
cf7427ad1d |
@@ -3793,6 +3793,26 @@ export default {
|
||||
{
|
||||
code: "riskAC_M",
|
||||
label: "元"
|
||||
},
|
||||
{
|
||||
code: "CardiovascularCerebrovascularDiseasesInsurance",
|
||||
label: "元"
|
||||
},
|
||||
{
|
||||
code: "childrenSpecificDiseaseInsurance",
|
||||
label: "元"
|
||||
},
|
||||
{
|
||||
code: "maleSpecificDiseaseInsurance",
|
||||
label: "元"
|
||||
},
|
||||
{
|
||||
code: "femaleSpecificDiseaseInsurance",
|
||||
label: "元"
|
||||
},
|
||||
{
|
||||
code: "supplementarySpecificDiseaseInsurance",
|
||||
label: "元"
|
||||
}
|
||||
],
|
||||
// 卡单与短期险重新投保选择职业类别时,两个模块职业类型数据的排序不同,创建这个数据字典,用于在选择职业类别时,作为一个参数传入组件,
|
||||
|
||||
@@ -13,9 +13,9 @@
|
||||
<van-tag type="primary" v-if="item.isMainRisk == 0" class="mr5 green" plain>主险</van-tag>
|
||||
<van-tag type="primary" v-else class="mr5 green" plain>附加险</van-tag>
|
||||
<span class="ml5 center fs13 flex1">{{ item.riskName }}</span>
|
||||
<van-tag type="primary" v-if="item.isMainRisk == 0 && item.hasAddtionRisk && isEnterAddtionRisk" plain @click="selectAddtionRisk" class="green mr8"
|
||||
>附</van-tag
|
||||
>
|
||||
<van-tag type="primary" v-if="item.isMainRisk == 0 && item.hasAddtionRisk && isEnterAddtionRisk" plain @click="selectAddtionRisk" class="green mr8">
|
||||
附
|
||||
</van-tag>
|
||||
<van-icon name="search" size="20" v-if="item.documentDTOS && item.documentDTOS.length > 0" @click="seeDocument(index)" class="green mr5" />
|
||||
<van-icon name="delete" size="22" @click="deleteRisk(index,item)" class="green" />
|
||||
</div>
|
||||
@@ -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,
|
||||
@@ -747,6 +747,42 @@ export default {
|
||||
}
|
||||
})
|
||||
}
|
||||
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(this.saleInsuredPersonInfo.insuredAge < 18) {
|
||||
if(ii.duty == '311504'){
|
||||
ii.necess = true
|
||||
ii.defaultValue = '0'
|
||||
} else {
|
||||
ii.defaultValue = '0'
|
||||
}
|
||||
}else{
|
||||
if(this.saleInsuredPersonInfo.sex == '0'){
|
||||
if(ii.duty == '311505'){
|
||||
ii.necess = true
|
||||
ii.defaultValue = '0'
|
||||
}
|
||||
if(ii.duty == '311504' || ii.duty == '311506'){
|
||||
ii.defaultValue = '0'
|
||||
}
|
||||
} else {
|
||||
if(ii.duty == '311506'){
|
||||
ii.defaultValue = '0'
|
||||
ii.necess = true
|
||||
}
|
||||
if(ii.duty == '311504' || ii.duty == '311505'){
|
||||
ii.defaultValue = '0'
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
})
|
||||
}
|
||||
if (item.mainRiskCode == 'GFRS_M0046') {
|
||||
if (this.saleInsuredPersonInfo.relationToAppnt == 1) {
|
||||
this.isEnterAddtionRiskListFunc()
|
||||
@@ -774,25 +810,11 @@ export default {
|
||||
}
|
||||
}
|
||||
|
||||
// if (item.productCode == 'GFRS_A0003') {
|
||||
// //该附加险的责任保额=主险的保费
|
||||
// item.calFactorLst.map(v => {
|
||||
// if (v.code == 'dutyGroup' && v.rules.length > 0) {
|
||||
// v.rules.map(y => {
|
||||
// if (y.defaultDutyAmt === null) {
|
||||
// y.defaultDutyAmt = (JSON.parse(localStorage.trialList)[0].prem / 10000).toFixed(6)
|
||||
// }
|
||||
// y.moneyUnit = 10000
|
||||
// y.changeWithMainRisk = true //责任险保额=主险保费,不允许用户手动更改
|
||||
// })
|
||||
// }
|
||||
// })
|
||||
// }
|
||||
//保存主险险种编号
|
||||
if (item.isMainRisk == 0) {
|
||||
this.mainRiskCode = item.mainRiskCode
|
||||
}
|
||||
})
|
||||
//保存主险险种编号
|
||||
if (item.isMainRisk == 0) {
|
||||
this.mainRiskCode = item.mainRiskCode
|
||||
}
|
||||
})
|
||||
if (this.mainRiskCode == 'GFRS_M0005') {
|
||||
this.chooseProducts.map((item) => {
|
||||
if (item.productCode == 'GFRS_A0004') {
|
||||
@@ -850,91 +872,6 @@ export default {
|
||||
rules.forEach((item) => {
|
||||
let config = ''
|
||||
config = JSON.parse(item.ruleExpression)
|
||||
// let errorMsg = item.errorMsg;
|
||||
// config = {
|
||||
// eventName: 'GFRS_M0020_payEndYear_insuYear',
|
||||
// eventType: 'onConfirm',
|
||||
// funBody: [
|
||||
// 'let ageMap = {',
|
||||
// ' "10Y":{"30Y": 55,"70A": 55,"88A": 55},',
|
||||
// ' "20Y":{ "30Y": 55, "70A": 50, "88A": 55 }, ',
|
||||
// ' "30Y":{ "30Y": 45, "70A": 40, "88A": 45 },',
|
||||
// '};',
|
||||
// 'let payEndYear = "";',
|
||||
// 'let insuYear = "";',
|
||||
// 'let age = this.saleInsuredPersonInfo.insuredAge;',
|
||||
// 'let parObj = {};',
|
||||
// 'par.map(item => {',
|
||||
// ' parObj[item.code] = item;',
|
||||
// '});',
|
||||
// 'if(ParKey == "payEndYear"){',
|
||||
// ' payEndYear = Par.value + Par.flag;',
|
||||
// ' lintAgeObj = ageMap[payEndYear];',
|
||||
// ' let flag = true, num = parObj.insuYear.columns.length;',
|
||||
// ' parObj.insuYear.columns.forEach(item => {',
|
||||
// ' let lintAge = lintAgeObj[ item.value + item.flag ];',
|
||||
// ' if( age > lintAge ){',
|
||||
// ' item.disabled = true;',
|
||||
// ' num = num - 1 ;',
|
||||
// ' }else{',
|
||||
// ' if(flag){',
|
||||
// ' parObj.insuYear.insuYear = item.value;',
|
||||
// ' parObj.insuYear.insuYearFlag = item.flag;',
|
||||
// ' parObj.insuYear.showContent = item.text;',
|
||||
// ' flag = false;',
|
||||
// ' };',
|
||||
// ' item.disabled = false;',
|
||||
// ' };',
|
||||
// ' });',
|
||||
// ' if(!num){',
|
||||
// ' this.errorMsg.push("被保险人年龄不符合当前所选交费期间");',
|
||||
// ' payEndYear = parObj.payEndYear.payEndYear + parObj.payEndYear.payEndYearFlag;',
|
||||
// ' lintAgeObj = ageMap[payEndYear];',
|
||||
// ' parObj.insuYear.columns.forEach(item => {',
|
||||
// ' let lintAge = lintAgeObj[ item.value + item.flag ];',
|
||||
// ' if( age > lintAge ){',
|
||||
// ' item.disabled = true;',
|
||||
// ' }else{',
|
||||
// ' item.disabled = false;',
|
||||
// ' };',
|
||||
// ' });',
|
||||
// ' return false;',
|
||||
// ' };',
|
||||
// ' return true;',
|
||||
// '}'],
|
||||
// funPar: ['par','ParKey','Par'],
|
||||
// }
|
||||
// config = {
|
||||
// eventName: 'GFRS_A0003_noMainCode',
|
||||
// eventType: 'init',
|
||||
// initBody: [
|
||||
// 'for(let item of that.chooseProducts){',
|
||||
// ' if(item.productCode == "GFRS_A0003"){',
|
||||
// ' for(let itemC of item.calFactorLst){',
|
||||
// ' if(itemC.code == "dutyGroup"){',
|
||||
// ' for(let itemR of itemC.rules){',
|
||||
// ' that.$emit("GFRS_A0003_noMainCode", itemR, that.mainRiskCode)',
|
||||
// ' }',
|
||||
// ' }',
|
||||
// ' }',
|
||||
// ' }',
|
||||
// ' }',
|
||||
// ],
|
||||
// funBody: [
|
||||
// 'let noMainCode = {',
|
||||
// ' "GFRS_M0004" : true,',
|
||||
// ' "GFRS_M0011" : true',
|
||||
// '};',
|
||||
// 'let noduty = {',
|
||||
// ' "310101" : true',
|
||||
// '};',
|
||||
// 'if(noMainCode[mainRiskCode] && noduty[dutyItem.duty]){',
|
||||
// ' dutyItem.necess = false;',
|
||||
// ' dutyItem.isDisabled = true;',
|
||||
// '}',
|
||||
// ],
|
||||
// funPar:['dutyItem', 'mainRiskCode'],
|
||||
// }
|
||||
this.$on(config.eventName, new Function(...config.funPar, config.funBody.join('')))
|
||||
if (config.eventType == 'init') {
|
||||
let initFn = new Function('that', config.initBody.join(''))
|
||||
@@ -1250,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) {
|
||||
@@ -1279,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') {
|
||||
@@ -2650,6 +2620,42 @@ export default {
|
||||
this.getTrial()
|
||||
}
|
||||
}
|
||||
else if (productCode == 'GFRS_M0076') {
|
||||
if (this.saleInsuredPersonInfo.insuredAge >= 51 && this.saleInsuredPersonInfo.insuredAge <= 60) {
|
||||
//使用rules规则里的第二条控制保额份数
|
||||
// 年龄在51周岁及以上被保险人,投保本险种时,最低基本保险金额为10000元。超过最低基本保险金额为10000元整数倍。
|
||||
if (Number(defalutValue) < Number(riskFactor.rules[1].minPrem) || Number(defalutValue) > Number(riskFactor.rules[1].maxPrem)) {
|
||||
this.$toast('51周岁-60周岁最低基本保险金额为'+ (Number(riskFactor.rules[1].minPrem) * 10000) +'元,最高投保金额为'+ (Number(riskFactor.rules[1].maxPrem) * 10000) +'元。')
|
||||
this.nextStepFlag = true
|
||||
} else {
|
||||
if ((Number(defalutValue) * 10000) % (Number(currentEle.limit) * 10000) != 0) {
|
||||
// this.defalutAmt = currentEle.rules[productIndex].displayAmount
|
||||
this.$toast('51周岁-60周岁最低基本保险金额为'+ (Number(riskFactor.rules[1].minPrem) * 10000) +'元,最高投保金额为'+ (Number(riskFactor.rules[1].maxPrem) * 10000) +'元。超过最低基本保险金额为'+ (Number(riskFactor.rules[1].limit) * 10000) +'元整数倍。')
|
||||
this.nextStepFlag = true
|
||||
} else {
|
||||
this.mainRiskInfluenceAddRisk()
|
||||
currentEle['amt'] = Number(defalutValue) * Number(currentEle.moneyUnit)
|
||||
this.getTrial()
|
||||
}
|
||||
}
|
||||
//年龄在0-50周岁被保险人,投保本险种时,最低基本保险金额为50000元,超过最低基本保险金额为10000元整数倍。
|
||||
} else if (this.saleInsuredPersonInfo.insuredAge >= 0 && this.saleInsuredPersonInfo.insuredAge <= 50) {
|
||||
//使用rules规则里的第一条控制保额份数
|
||||
if (Number(defalutValue) < Number(riskFactor.rules[0].minPrem) || Number(defalutValue) > Number(riskFactor.rules[0].maxPrem)) {
|
||||
this.$toast('出生满 28 天至 50周岁最低基本保险金额为'+ (Number(riskFactor.rules[0].minPrem) * 10000) +'元,最高投保金额为'+ (Number(riskFactor.rules[0].maxPrem) * 10000) +'元。')
|
||||
this.nextStepFlag = true
|
||||
} else {
|
||||
if ((Number(defalutValue) * 10000) % (Number(currentEle.limit) * 10000) != 0) {
|
||||
this.$toast('出生满 28 天至 50周岁最低基本保险金额为'+ (Number(riskFactor.rules[0].minPrem) * 10000) +'元,最高投保金额为'+ (Number(riskFactor.rules[0].maxPrem) * 10000) +'元。超过最低基本保险金额为'+ (Number(riskFactor.rules[0].limit) * 10000) +'元整数倍。')
|
||||
this.nextStepFlag = true
|
||||
} else {
|
||||
this.mainRiskInfluenceAddRisk()
|
||||
currentEle['amt'] = Number(defalutValue) * Number(currentEle.moneyUnit)
|
||||
this.getTrial()
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (this.isTrial === '0' && this.chooseProducts[productIndex].isMainRisk == '0') {
|
||||
if (Number(defalutValue) < Number(min)) {
|
||||
if (riskFactor.yearWay == "一次性交清") {
|
||||
@@ -2809,6 +2815,7 @@ export default {
|
||||
this.trialList[index].productCode == 'GFRS_M0051' ||
|
||||
this.trialList[index].productCode == 'GFRS_M0054' ||
|
||||
this.trialList[index].productCode == 'GFRS_M0073' ||
|
||||
this.trialList[index].productCode == 'GFRS_M0077' ||
|
||||
this.trialList[index].productCode == 'GFRS_M0057'
|
||||
) {
|
||||
riskItem['dutyLst'] = this.trialInfos[index].duty
|
||||
@@ -2845,7 +2852,7 @@ export default {
|
||||
this.trialInfos[index].amt = this.trialList[index].amt
|
||||
}
|
||||
// GFRS_A0009,GFRS_A0010 这两款时,责任保额不相加
|
||||
if(item.productCode == 'GFRS_A0009' || item.productCode == 'GFRS_A0010' || item.productCode == 'GFRS_A0013'|| item.productCode == 'GFRS_A0014'){
|
||||
if(item.productCode == 'GFRS_A0009' || item.productCode == 'GFRS_A0010' || item.productCode == 'GFRS_A0013'|| item.productCode == 'GFRS_A0014' || item.productCode == 'GFRS_M0077'){
|
||||
this.trialInfos[index].amt = this.trialList[index].duty[0].amt
|
||||
}
|
||||
// GFRS_A0011-附加两全 属于非豁免险 但附加两全保额=主险年交保费+其他不带豁免责任的长期期交附加险年交保费
|
||||
@@ -2871,7 +2878,7 @@ export default {
|
||||
//国富人寿桂企保重大疾病保险产品专写
|
||||
this.trialInfos.map((v, i) => {
|
||||
if (v.productCode == 'GFRS_M0024' || v.productCode == 'GFRS_M0040' || v.productCode == 'GFRS_M0044'
|
||||
|| v.productCode == 'GFRS_M0046'|| v.productCode == 'GFRS_M0051'|| v.productCode == 'GFRS_M0057' || v.productCode == 'GFRS_M0073') {
|
||||
|| v.productCode == 'GFRS_M0046'|| v.productCode == 'GFRS_M0051'|| v.productCode == 'GFRS_M0057' || v.productCode == 'GFRS_M0073'|| v.productCode == 'GFRS_M0077') {
|
||||
delete riskDTOLst[i].duty
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user