mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-10 02:16:44 +08:00
一年期产品的特殊处理默认选择指定责任
This commit is contained in:
@@ -13,9 +13,9 @@
|
|||||||
<van-tag type="primary" v-if="item.isMainRisk == 0" class="mr5 green" plain>主险</van-tag>
|
<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>
|
<van-tag type="primary" v-else class="mr5 green" plain>附加险</van-tag>
|
||||||
<span class="ml5 center fs13 flex1">{{ item.riskName }}</span>
|
<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 type="primary" v-if="item.isMainRisk == 0 && item.hasAddtionRisk && isEnterAddtionRisk" plain @click="selectAddtionRisk" class="green mr8">
|
||||||
>附</van-tag
|
附
|
||||||
>
|
</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="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" />
|
<van-icon name="delete" size="22" @click="deleteRisk(index,item)" class="green" />
|
||||||
</div>
|
</div>
|
||||||
@@ -135,10 +135,10 @@
|
|||||||
:max="dutyItem.maxDutyAmt"
|
:max="dutyItem.maxDutyAmt"
|
||||||
:show-plus="false"
|
:show-plus="false"
|
||||||
:show-minus="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"
|
class="ml10 mr10"
|
||||||
@focus="focusStep"
|
@focus="focusStep"
|
||||||
@blur="blurStep(dutyItem, index)"
|
@blur="blurStep(dutyItem, index,item.productCode)"
|
||||||
@change="
|
@change="
|
||||||
dutyStepperChange(
|
dutyStepperChange(
|
||||||
item.calFactorLst[riskFactorIndex].rules[dutyItemIndex].defaultDutyAmt,
|
item.calFactorLst[riskFactorIndex].rules[dutyItemIndex].defaultDutyAmt,
|
||||||
@@ -353,21 +353,31 @@
|
|||||||
<van-dialog v-model="trialResultsShow" title="核保试算结果" :show-cancel-button="false">
|
<van-dialog v-model="trialResultsShow" title="核保试算结果" :show-cancel-button="false">
|
||||||
<div class="pl40 pr40 mt10">
|
<div class="pl40 pr40 mt10">
|
||||||
<div class="flex justify-content-s fs12" v-for="(item, index) in verifyResultList" :key="index">
|
<div class="flex justify-content-s fs12" v-for="(item, index) in verifyResultList" :key="index">
|
||||||
<div><img class="w20 h20 p10 v-middle" :src="require('@/assets/images/sale/ruleType0'+ item.ruleType +'.png')" alt=""><span class="v-middle">{{item.ruleType | ruleTypeFilter}}</span></div>
|
<div>
|
||||||
<div><span class="v-middle">{{item.status | approvedFilter}}</span><img class="w20 h20 p10 v-middle" :src="require('@/assets/images/sale/approved'+ item.status +'.png')" alt=""></div>
|
<img class="w20 h20 p10 v-middle" :src="require('@/assets/images/sale/ruleType0'+ item.ruleType +'.png')" alt="">
|
||||||
|
<span class="v-middle">{{item.ruleType | ruleTypeFilter}}</span>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<!-- <span class="v-middle">{{item.status | approvedFilter}}</span>-->
|
||||||
|
<img class="w20 h20 p10 v-middle" :src="require('@/assets/images/sale/approved'+ item.status +'.png')" alt="">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div style="padding:25px 0px 10px 10px;font-size: 10px;color: #999;">
|
||||||
|
<p style="line-height: 20px;"><span style="width: 40px;display: inline-block;">说明:</span>绿色✔表示 未触发规则、红色×表示 触发规则</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</van-dialog>
|
</van-dialog>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { Tag, Icon, Dialog, ActionSheet, Popup, Picker, Stepper, Field, Checkbox, RadioGroup, Radio } from 'vant'
|
import { Tag, Icon, Dialog, ActionSheet, Popup, Picker, Stepper, Field, Checkbox, RadioGroup, Radio } from 'vant'
|
||||||
import { trial } from '@/api/ebiz/common/common'
|
import { trial } from '@/api/ebiz/common/common'
|
||||||
import { saveOrUpdateOrderInfo, getOrderDetail,orderTrial } from '@/api/ebiz/sale/sale'
|
import { saveOrUpdateOrderInfo, getOrderDetail,orderTrial } from '@/api/ebiz/sale/sale'
|
||||||
import { saveProposal, getTrialRecordInfo, saveOrUpdateTrialRecordInfo } from '@/api/ebiz/proposal/proposal.js'
|
import { saveProposal, getTrialRecordInfo, saveOrUpdateTrialRecordInfo } from '@/api/ebiz/proposal/proposal.js'
|
||||||
import { getAgentInfo } from '@/api/ebiz/my/my.js'
|
import { getAgentInfo } from '@/api/ebiz/my/my.js'
|
||||||
import occupationList from '@/components/ebiz/occipation/data/occupation'
|
import occupationList from '@/components/ebiz/occipation/data/occupation'
|
||||||
import riskRules from "./risk-rules";
|
import utilsAge from '@/assets/js/utils/age'
|
||||||
|
import riskRules from "./risk-rules";
|
||||||
|
|
||||||
//险种GFRS_M0016的责任的验证规则
|
//险种GFRS_M0016的责任的验证规则
|
||||||
//默认 最低基本保险金额min 10000 整数倍要求mutiple 1000
|
//默认 最低基本保险金额min 10000 整数倍要求mutiple 1000
|
||||||
@@ -475,7 +485,7 @@ import riskRules from "./risk-rules";
|
|||||||
const DUTY_DEFAULT_MUTIPLE = 1000
|
const DUTY_DEFAULT_MUTIPLE = 1000
|
||||||
const DUTY_DEFAULT_MIN = 10000
|
const DUTY_DEFAULT_MIN = 10000
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
name: 'calculatePremium',
|
name: 'calculatePremium',
|
||||||
filters: {
|
filters: {
|
||||||
ruleTypeFilter(val) {
|
ruleTypeFilter(val) {
|
||||||
@@ -655,6 +665,9 @@ export default {
|
|||||||
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
if (this.$CacheUtils.getLocItem('saleInsuredPersonInfo')) {
|
||||||
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
this.saleInsuredPersonInfo = JSON.parse(this.$CacheUtils.getLocItem('saleInsuredPersonInfo'))
|
||||||
this.saleInsuredPersonInfo.insuredAge = this.saleInsuredPersonInfo.insuredAge ? this.saleInsuredPersonInfo.insuredAge : this.saleInsuredPersonInfo.age
|
this.saleInsuredPersonInfo.insuredAge = this.saleInsuredPersonInfo.insuredAge ? this.saleInsuredPersonInfo.insuredAge : this.saleInsuredPersonInfo.age
|
||||||
|
if(this.saleInsuredPersonInfo.birthday){
|
||||||
|
this.saleInsuredPersonInfo.insuredAge = utilsAge.getAge(this.saleInsuredPersonInfo.birthday, new Date())
|
||||||
|
}
|
||||||
if (this.isFrom == 'proposal' && !this.saleInsuredPersonInfo.name) {
|
if (this.isFrom == 'proposal' && !this.saleInsuredPersonInfo.name) {
|
||||||
// 建议书投保人/被保人姓名不必填, 填写姓名时展示姓名(落库),不填写姓名时展示性别+年龄,如:男30岁(不落库)
|
// 建议书投保人/被保人姓名不必填, 填写姓名时展示姓名(落库),不填写姓名时展示性别+年龄,如:男30岁(不落库)
|
||||||
let sex = this.saleInsuredPersonInfo.sex == '0'?'男':'女'
|
let sex = this.saleInsuredPersonInfo.sex == '0'?'男':'女'
|
||||||
@@ -734,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 (item.mainRiskCode == 'GFRS_M0046') {
|
||||||
if (this.saleInsuredPersonInfo.relationToAppnt == 1) {
|
if (this.saleInsuredPersonInfo.relationToAppnt == 1) {
|
||||||
this.isEnterAddtionRiskListFunc()
|
this.isEnterAddtionRiskListFunc()
|
||||||
@@ -761,20 +810,6 @@ 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) {
|
if (item.isMainRisk == 0) {
|
||||||
this.mainRiskCode = item.mainRiskCode
|
this.mainRiskCode = item.mainRiskCode
|
||||||
@@ -837,91 +872,6 @@ export default {
|
|||||||
rules.forEach((item) => {
|
rules.forEach((item) => {
|
||||||
let config = ''
|
let config = ''
|
||||||
config = JSON.parse(item.ruleExpression)
|
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('')))
|
this.$on(config.eventName, new Function(...config.funPar, config.funBody.join('')))
|
||||||
if (config.eventType == 'init') {
|
if (config.eventType == 'init') {
|
||||||
let initFn = new Function('that', config.initBody.join(''))
|
let initFn = new Function('that', config.initBody.join(''))
|
||||||
@@ -1237,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)
|
this.valiAndSend(dutyItem, productIndex)
|
||||||
},
|
},
|
||||||
valiAndSend(dutyItem, productIndex) {
|
valiAndSend(dutyItem, productIndex) {
|
||||||
@@ -1266,14 +1233,30 @@ export default {
|
|||||||
focusStep() {
|
focusStep() {
|
||||||
this.nextStepFlag = true
|
this.nextStepFlag = true
|
||||||
},
|
},
|
||||||
blurStep(dutyItem, productIndex) {
|
blurStep(dutyItem, productIndex, productCode) {
|
||||||
this.nextStepFlag = false
|
this.nextStepFlag = false
|
||||||
|
|
||||||
//失去焦点时做验证
|
//失去焦点时做验证
|
||||||
if (dutyItem.necess) {
|
if (dutyItem.necess) {
|
||||||
//勾选时才做验证
|
//勾选时才做验证
|
||||||
this.valiAndSend(dutyItem, productIndex)
|
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的责任的验证规则
|
//险种GFRS_M0016\GFRS_M0070的责任的验证规则
|
||||||
valiDuty(value, duty) {
|
valiDuty(value, duty) {
|
||||||
@@ -2338,7 +2321,7 @@ export default {
|
|||||||
this.saleInsuredInfo.sex,
|
this.saleInsuredInfo.sex,
|
||||||
this.saleInsuredInfo.occupationCode,
|
this.saleInsuredInfo.occupationCode,
|
||||||
this.saleInsuredInfo.occupationName,
|
this.saleInsuredInfo.occupationName,
|
||||||
this.saleInsuredInfo.insuredAge?this.saleInsuredInfo.insuredAge:this.saleInsuredInfo.age,
|
this.saleInsuredPersonInfo.insuredAge
|
||||||
]
|
]
|
||||||
} else {
|
} else {
|
||||||
;[birthday, sex, occupationCode, occupationName, age] = [
|
;[birthday, sex, occupationCode, occupationName, age] = [
|
||||||
@@ -2346,7 +2329,7 @@ export default {
|
|||||||
this.saleInsuredPersonInfo.sex,
|
this.saleInsuredPersonInfo.sex,
|
||||||
this.saleInsuredPersonInfo.occupationCode,
|
this.saleInsuredPersonInfo.occupationCode,
|
||||||
this.saleInsuredPersonInfo.occupationName,
|
this.saleInsuredPersonInfo.occupationName,
|
||||||
this.saleInsuredPersonInfo.insuredAge?this.saleInsuredPersonInfo.insuredAge:this.saleInsuredPersonInfo.age
|
this.saleInsuredPersonInfo.insuredAge
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
trialInfo = Object.assign(trialInfo, {
|
trialInfo = Object.assign(trialInfo, {
|
||||||
@@ -2404,10 +2387,24 @@ export default {
|
|||||||
},
|
},
|
||||||
//保额份数变化
|
//保额份数变化
|
||||||
stepperChange(defalutValue, productIndex, calFactorIndex, min, max, riskFactor) {
|
stepperChange(defalutValue, productIndex, calFactorIndex, min, max, riskFactor) {
|
||||||
let currentEle =
|
let currentEle = ''
|
||||||
localStorage.isTrial !== '1' && this.chooseProducts[productIndex].isMainRisk == '0'
|
let params = this.getParams()
|
||||||
? this.chooseProducts[productIndex].productTrialYearDTOS[calFactorIndex]
|
if(localStorage.isTrial !== '1' && this.chooseProducts[productIndex].isMainRisk == '0'){
|
||||||
: this.chooseProducts[productIndex].calFactorLst[calFactorIndex]
|
// params[productIndex].payEndYear == '1000' 交费期间为一次性交清
|
||||||
|
this.chooseProducts[productIndex].productTrialYearDTOS.forEach(item=>{
|
||||||
|
if(params.trialInfos[productIndex].payEndYear == '1000') {
|
||||||
|
if(item.yearWay == '一次性交清'){
|
||||||
|
currentEle = item
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if(item.yearWay == params.trialInfos[productIndex].payEndYear){
|
||||||
|
currentEle = item
|
||||||
|
}
|
||||||
|
}
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
currentEle = this.chooseProducts[productIndex].calFactorLst[calFactorIndex]
|
||||||
|
}
|
||||||
//改动原因:孝心保产品有对年龄的特殊要求
|
//改动原因:孝心保产品有对年龄的特殊要求
|
||||||
//添加判断,是否是孝心保产品
|
//添加判断,是否是孝心保产品
|
||||||
let showHint = this.chooseProducts[productIndex].hint
|
let showHint = this.chooseProducts[productIndex].hint
|
||||||
@@ -2449,7 +2446,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//isTrial为0 ---暂时为富娃娃两全保险(万能型)专配 输入保费校验
|
//isTrial为0 ---暂时为富娃娃两全保险(万能型)专配 输入保费校验
|
||||||
} else if (productCode == 'GFRS_M0035' || productCode == 'GFRS_M0044'
|
}
|
||||||
|
else if (productCode == 'GFRS_M0035' || productCode == 'GFRS_M0044'
|
||||||
|| productCode == 'GFRS_M0056' || productCode == 'GFRS_M0057' || productCode == 'GFRS_M0060') {
|
|| productCode == 'GFRS_M0056' || productCode == 'GFRS_M0057' || productCode == 'GFRS_M0060') {
|
||||||
console.log('defalutValue==', defalutValue)
|
console.log('defalutValue==', defalutValue)
|
||||||
console.log("currentEle['amt']==", currentEle['amt'])
|
console.log("currentEle['amt']==", currentEle['amt'])
|
||||||
@@ -2492,7 +2490,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//isTrial为0 ---暂时为富娃娃两全保险(万能型)专配 输入保费校验
|
//isTrial为0 ---暂时为富娃娃两全保险(万能型)专配 输入保费校验
|
||||||
} else if (productCode == 'GFRS_M0040') {
|
}
|
||||||
|
else if (productCode == 'GFRS_M0040') {
|
||||||
// 惠企保保额限制
|
// 惠企保保额限制
|
||||||
//被保险人年龄如果在41-60区间
|
//被保险人年龄如果在41-60区间
|
||||||
if (this.saleInsuredPersonInfo.insuredAge >= 41) {
|
if (this.saleInsuredPersonInfo.insuredAge >= 41) {
|
||||||
@@ -2529,7 +2528,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//isTrial为0 ---暂时为富娃娃两全保险(万能型)专配 输入保费校验
|
//isTrial为0 ---暂时为富娃娃两全保险(万能型)专配 输入保费校验
|
||||||
} else if (productCode == 'GFRS_M0046') {
|
}
|
||||||
|
else if (productCode == 'GFRS_M0046') {
|
||||||
//被保险人年龄如果在50-65区间
|
//被保险人年龄如果在50-65区间
|
||||||
if(this.branchTypeVal == 'Z'){ //中介渠道规则
|
if(this.branchTypeVal == 'Z'){ //中介渠道规则
|
||||||
if (this.saleInsuredPersonInfo.insuredAge >= 51 && this.saleInsuredPersonInfo.insuredAge <= 60) {
|
if (this.saleInsuredPersonInfo.insuredAge >= 51 && this.saleInsuredPersonInfo.insuredAge <= 60) {
|
||||||
@@ -2604,7 +2604,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 国富人寿富桂金生养老年金保险(GFRS_M0053)中介渠道鑫享金生养老年金保险(GFRS_M0061)
|
// 国富人寿富桂金生养老年金保险(GFRS_M0053)中介渠道鑫享金生养老年金保险(GFRS_M0061)
|
||||||
} else if (productCode == 'GFRS_M0053' || productCode == 'GFRS_M0061') {
|
}
|
||||||
|
else if (productCode == 'GFRS_M0053' || productCode == 'GFRS_M0061') {
|
||||||
if (Number(defalutValue) < Number(min)) {
|
if (Number(defalutValue) < Number(min)) {
|
||||||
if (riskFactor.yearWay == "一次性交清") {
|
if (riskFactor.yearWay == "一次性交清") {
|
||||||
this.$toast(`交费期间为${riskFactor.yearWay}时,最低保费为${Number(min) * Number(riskFactor.moneyUnit)}元`)
|
this.$toast(`交费期间为${riskFactor.yearWay}时,最低保费为${Number(min) * Number(riskFactor.moneyUnit)}元`)
|
||||||
@@ -2618,7 +2619,44 @@ export default {
|
|||||||
currentEle['amt'] = Number(defalutValue) * Number(riskFactor.moneyUnit)
|
currentEle['amt'] = Number(defalutValue) * Number(riskFactor.moneyUnit)
|
||||||
this.getTrial()
|
this.getTrial()
|
||||||
}
|
}
|
||||||
} else if (this.isTrial === '0' && this.chooseProducts[productIndex].isMainRisk == '0') {
|
}
|
||||||
|
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 (Number(defalutValue) < Number(min)) {
|
||||||
if (riskFactor.yearWay == "一次性交清") {
|
if (riskFactor.yearWay == "一次性交清") {
|
||||||
this.$toast(`交费期间为${riskFactor.yearWay}时,最低保费为${Number(min) * Number(riskFactor.moneyUnit)}元`)
|
this.$toast(`交费期间为${riskFactor.yearWay}时,最低保费为${Number(min) * Number(riskFactor.moneyUnit)}元`)
|
||||||
@@ -2639,7 +2677,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
//其他产品按照原先的逻辑判断
|
//其他产品按照原先的逻辑判断
|
||||||
} else if (this.isTrial === '0' && this.chooseProducts[productIndex].isMainRisk == '1') {
|
}
|
||||||
|
else if (this.isTrial === '0' && this.chooseProducts[productIndex].isMainRisk == '1') {
|
||||||
if (Number(defalutValue) < Number(min) || Number(defalutValue) > Number(max)) {
|
if (Number(defalutValue) < Number(min) || Number(defalutValue) > Number(max)) {
|
||||||
this.$toast('投保本险种最低基本保险金额为10000元,超过最低基本保险金额为1000元整数倍')
|
this.$toast('投保本险种最低基本保险金额为10000元,超过最低基本保险金额为1000元整数倍')
|
||||||
this.nextStepFlag = true
|
this.nextStepFlag = true
|
||||||
@@ -2654,7 +2693,8 @@ export default {
|
|||||||
this.getTrial()
|
this.getTrial()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
} else {
|
}
|
||||||
|
else {
|
||||||
if (Number(defalutValue) < Number(min) || Number(defalutValue) > Number(max)) {
|
if (Number(defalutValue) < Number(min) || Number(defalutValue) > Number(max)) {
|
||||||
this.$toast(showHint)
|
this.$toast(showHint)
|
||||||
this.nextStepFlag = true
|
this.nextStepFlag = true
|
||||||
@@ -2775,6 +2815,7 @@ export default {
|
|||||||
this.trialList[index].productCode == 'GFRS_M0051' ||
|
this.trialList[index].productCode == 'GFRS_M0051' ||
|
||||||
this.trialList[index].productCode == 'GFRS_M0054' ||
|
this.trialList[index].productCode == 'GFRS_M0054' ||
|
||||||
this.trialList[index].productCode == 'GFRS_M0073' ||
|
this.trialList[index].productCode == 'GFRS_M0073' ||
|
||||||
|
this.trialList[index].productCode == 'GFRS_M0077' ||
|
||||||
this.trialList[index].productCode == 'GFRS_M0057'
|
this.trialList[index].productCode == 'GFRS_M0057'
|
||||||
) {
|
) {
|
||||||
riskItem['dutyLst'] = this.trialInfos[index].duty
|
riskItem['dutyLst'] = this.trialInfos[index].duty
|
||||||
@@ -2811,7 +2852,7 @@ export default {
|
|||||||
this.trialInfos[index].amt = this.trialList[index].amt
|
this.trialInfos[index].amt = this.trialList[index].amt
|
||||||
}
|
}
|
||||||
// GFRS_A0009,GFRS_A0010 这两款时,责任保额不相加
|
// 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
|
this.trialInfos[index].amt = this.trialList[index].duty[0].amt
|
||||||
}
|
}
|
||||||
// GFRS_A0011-附加两全 属于非豁免险 但附加两全保额=主险年交保费+其他不带豁免责任的长期期交附加险年交保费
|
// GFRS_A0011-附加两全 属于非豁免险 但附加两全保额=主险年交保费+其他不带豁免责任的长期期交附加险年交保费
|
||||||
@@ -2837,7 +2878,7 @@ export default {
|
|||||||
//国富人寿桂企保重大疾病保险产品专写
|
//国富人寿桂企保重大疾病保险产品专写
|
||||||
this.trialInfos.map((v, i) => {
|
this.trialInfos.map((v, i) => {
|
||||||
if (v.productCode == 'GFRS_M0024' || v.productCode == 'GFRS_M0040' || v.productCode == 'GFRS_M0044'
|
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
|
delete riskDTOLst[i].duty
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
@@ -2845,7 +2886,7 @@ export default {
|
|||||||
//建议书需要添加全部投保人信息,电投只需要投保人ID
|
//建议书需要添加全部投保人信息,电投只需要投保人ID
|
||||||
let insuredDTOItem = Object.assign(this.saleInsuredPersonInfo, { riskDTOLst: riskDTOLst })
|
let insuredDTOItem = Object.assign(this.saleInsuredPersonInfo, { riskDTOLst: riskDTOLst })
|
||||||
if (!insuredDTOItem.insuredAge) {
|
if (!insuredDTOItem.insuredAge) {
|
||||||
insuredDTOItem.insuredAge = insuredDTOItem.age
|
insuredDTOItem.insuredAge = insuredDTOItem.birthday ? utilsAge.getAge(insuredDTOItem.birthday, new Date()) : insuredDTOItem.age
|
||||||
}
|
}
|
||||||
let orderNo = localStorage.isFrom == 'proposal'?this.$route.query.proposalOrderNo:this.$route.query.orderNo
|
let orderNo = localStorage.isFrom == 'proposal'?this.$route.query.proposalOrderNo:this.$route.query.orderNo
|
||||||
let params = {
|
let params = {
|
||||||
@@ -2956,7 +2997,7 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
let data = {
|
let data = {
|
||||||
serialNo:this.$CacheUtils.getLocItem('proposalNo'),
|
serialNo:this.$route.query.proposalOrderNo,
|
||||||
mainRiskId:insuanceId+'',
|
mainRiskId:insuanceId+'',
|
||||||
trialJsonStr:localStorage.chooseProducts
|
trialJsonStr:localStorage.chooseProducts
|
||||||
}
|
}
|
||||||
@@ -3026,39 +3067,39 @@ export default {
|
|||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
<style lang="scss" scoped>
|
<style lang="scss" scoped>
|
||||||
/deep/ .van-dialog .van-dialog__header{
|
/deep/ .van-dialog .van-dialog__header{
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
font-weight: 700;
|
font-weight: 700;
|
||||||
}
|
}
|
||||||
/deep/ .van-button--danger{
|
/deep/ .van-button--danger{
|
||||||
border-radius: 0;
|
border-radius: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/deep/ .van-button--plain {
|
/deep/ .van-button--plain {
|
||||||
border: none !important;
|
border: none !important;
|
||||||
border-top: 1px solid #E9332E !important;
|
border-top: 1px solid #E9332E !important;
|
||||||
}
|
}
|
||||||
.renewalWrappser {
|
.renewalWrappser {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
/deep/ .van-radio {
|
/deep/ .van-radio {
|
||||||
margin: 0 0.5em;
|
margin: 0 0.5em;
|
||||||
}
|
}
|
||||||
|
|
||||||
.renewal {
|
.renewal {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: flex-end;
|
justify-content: flex-end;
|
||||||
padding: 1em;
|
padding: 1em;
|
||||||
}
|
}
|
||||||
|
|
||||||
/deep/ .van-radio__label {
|
/deep/ .van-radio__label {
|
||||||
line-height: normal;
|
line-height: normal;
|
||||||
}
|
}
|
||||||
|
|
||||||
.calculate-premium-container {
|
.calculate-premium-container {
|
||||||
.border-bottom {
|
.border-bottom {
|
||||||
border-bottom: 1px solid #dadada;
|
border-bottom: 1px solid #dadada;
|
||||||
}
|
}
|
||||||
@@ -3081,5 +3122,5 @@ export default {
|
|||||||
.van-dialog__content{
|
.van-dialog__content{
|
||||||
border: 1px solid red;
|
border: 1px solid red;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user