From c60d512aa3bd4da270233239619b722f7c553343 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E7=9A=AE=E4=BC=9F?= Date: Thu, 5 Dec 2019 17:04:08 +0800 Subject: [PATCH] =?UTF-8?q?=E6=8F=90=E4=BA=A4=E4=BF=9D=E8=B4=B9=E8=AE=A1?= =?UTF-8?q?=E7=AE=97?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ebiz/common/CalculatePremium.vue | 36 +++++++++++++++++----- src/views/ebiz/proposal/Exhibition.vue | 2 +- 2 files changed, 30 insertions(+), 8 deletions(-) diff --git a/src/views/ebiz/common/CalculatePremium.vue b/src/views/ebiz/common/CalculatePremium.vue index 45325f3cf..52b397d7f 100644 --- a/src/views/ebiz/common/CalculatePremium.vue +++ b/src/views/ebiz/common/CalculatePremium.vue @@ -29,6 +29,8 @@ v-model="item.calFactorLst[riskFactorIndex].defaultValue" :min="riskFactor.minAmt || riskFactor.minPrem" :max="riskFactor.maxAmt || riskFactor.maxPrem" + :show-plus="false" + :show-minus="false" class="ml10" @change="stepperChange(item.calFactorLst[riskFactorIndex].defaultValue, index, riskFactorIndex)" input-width="100" @@ -60,6 +62,8 @@ v-model="dutyItem.defaultDutyAmt" :min="dutyItem.minDutyAmt" :max="dutyItem.maxDutyAmt" + :show-plus="false" + :show-minus="false" class="ml10 mr10" @focus="focusStep" @blur="blurStep" @@ -165,7 +169,7 @@ export default { influenceAddRiskCodes: [], influences: [], nextStepFlag: false, - isFrom: localStorage.isFrom === 'sale', + isFrom: localStorage.isRelated === '0', policyNo: '', //关联保单号 // 份数 mult: '' @@ -198,12 +202,16 @@ export default { //构建提交数据、渲染险种 this.chooseProducts = JSON.parse(localStorage.chooseProducts) this.chooseProducts.map(item => { + if (item.mainRiskCode == 'GFRS_M0006') { + item.isHidden = true + } item.calFactorLst.map(i => { if (i.defaultValue) { this.mult = i.defaultValue } }) }) + // this.influenceAddRiskCodes if (this.chooseProducts[0].influences && this.chooseProducts[0].influences.length > 0) { @@ -243,6 +251,7 @@ export default { }, //弹框选择 toSelect(index, index1, columns) { + console.log(index, index1, columns) ;[this.popupShow, this.productIndex, this.calFactorIndex] = [true, index, index1] this.columns = columns }, @@ -256,7 +265,9 @@ export default { this.columns = [] let currentFactor = this.chooseProducts[this.productIndex].calFactorLst let currentEle = currentFactor[this.calFactorIndex] - + console.log('value', value) + console.log('currentFactor', currentFactor) + console.log('currentEle', currentEle) if (currentEle.showContent != value.text) { //通用规则校验 if (this.payExceedInsured(currentEle, currentFactor, value.value)) { @@ -604,11 +615,11 @@ export default { this.chooseProducts.forEach((item, index) => { let trialInfo = {} item.calFactorLst.forEach(factor => { - //type 类型 0为picker 1计步器 2职业等级 if (factor.type == 0) { if (factor.hasFlag == '1') { trialInfo[factor.code] = factor[factor.code] trialInfo[factor.code + 'Flag'] = factor[factor.code + 'Flag'] + // trialInfo[factor.payEndYear] = factor[factor.payEndYear] } else { trialInfo[factor.code] = factor[factor.code] } @@ -637,8 +648,9 @@ export default { }) //通用规则1:交费方式为一次交情,无交费期限 if (trialInfo['payIntv'] == '0') { - trialInfo['payEndYear'] = '1' + trialInfo['payEndYear'] = '1000' trialInfo['payEndYearFlag'] = 'Y' + trialInfo['insuYearFlag'] = 'Y' } //责任险参数构建 // if (trialInfo.duty) { @@ -699,9 +711,19 @@ export default { console.log(value) this.mult = value let currentEle = this.chooseProducts[productIndex].calFactorLst[calFactorIndex] - this.mainRiskInfluenceAddRisk() - currentEle['amt'] = Number(currentEle.defaultValue) * Number(currentEle.moneyUnit) - this.getTrial() + if ((Number(value) * 10000) % (Number(currentEle.limit) * 10000) != 0) { + currentEle.defaultValue = currentEle.rules[productIndex].defaultValue + Dialog.alert({ + message: `输入不能超过${Number(currentEle.limit) * 10000}的倍数` + }).then(() => { + // on close + }) + } else { + this.mainRiskInfluenceAddRisk() + currentEle['amt'] = Number(currentEle.defaultValue) * Number(currentEle.moneyUnit) + this.getTrial() + } + }, //下一步 async nextStep() { diff --git a/src/views/ebiz/proposal/Exhibition.vue b/src/views/ebiz/proposal/Exhibition.vue index 1d86c5f0a..7705dac51 100644 --- a/src/views/ebiz/proposal/Exhibition.vue +++ b/src/views/ebiz/proposal/Exhibition.vue @@ -271,7 +271,7 @@ export default { let { name, phoneNo, certificateInfoList } = agentResult if (certificateInfoList != null && certificateInfoList != '') { certificateInfoList.forEach(c => { - if (c.certificateType == '1') { + if (c.certificateType == '0') { agent.certificate = c.certificateNo } })