【国富人寿】建议书选择产品页面编辑按钮跳转链接参数拼接字段名称修改以及保费试算页面接口请求入参字段名称添加逻辑判断

This commit is contained in:
liu.xiaofeng@ebiz-digits.com
2023-05-18 17:29:21 +08:00
parent d0def37fa6
commit 42146430d0
2 changed files with 126 additions and 56 deletions

View File

@@ -691,12 +691,21 @@
//构建提交数据、渲染险种 //构建提交数据、渲染险种
if(this.$route.query.insuanceId && this.isFrom == 'proposal'){ if(this.$route.query.insuanceId && this.isFrom == 'proposal'){
// 获取试算记录详情 // 获取试算记录详情
let serialNo = ''
if (this.$route.query.orderNo) {
serialNo = this.$route.query.orderNo
}
if (this.$route.query.proposalOrderNo) {
serialNo = this.$route.query.proposalOrderNo
}
await getTrialRecordInfo({ await getTrialRecordInfo({
serialNo:this.$CacheUtils.getLocItem('proposalNo'), serialNo:serialNo,
mainRiskId:this.$route.query.insuanceId mainRiskId:this.$route.query.insuanceId
}).then(res => { }).then(res => {
if (res.result == '0') { if (res.result == '0') {
this.chooseProducts = JSON.parse(res.content.trialJsonStr) this.chooseProducts = JSON.parse(res.content.trialJsonStr)
} else {
this.$toast(res.resultMessage)
} }
}) })
}else{ }else{

View File

@@ -161,6 +161,12 @@ export default {
[Image.name]: Image [Image.name]: Image
}, },
mounted() { mounted() {
this.$jump({
flag: 'navigation',
extra: {
title: '已选产品列表'
},
})
if (localStorage.isFrom == 'sale') { if (localStorage.isFrom == 'sale') {
// 清除活动标志 // 清除活动标志
// localStorage.removeItem('active_type') // localStorage.removeItem('active_type')
@@ -172,6 +178,20 @@ export default {
}) })
}, 100) }, 100)
} }
//建议书--右上角为退出流程键(到建议书列表)×,并清除浏览记录
if (localStorage.isFrom == 'proposal') {
// eslint-disable-next-line no-undef
setTimeout(() => {
EWebBridge.webCallAppInJs('webview_right_button', {
btns: [
{
img: this.$assetsUrl + 'images/del-close.png',
route: { flag: '', extra: {} }
}
]
})
}, 500)
}
window.appCallBack = this.appCallBack window.appCallBack = this.appCallBack
document.body.style.backgroundColor = '#fff' document.body.style.backgroundColor = '#fff'
this.getProductList() this.getProductList()
@@ -232,6 +252,32 @@ export default {
.catch(() => { .catch(() => {
return return
}) })
}else if (data.trigger == 'right_button_click' && localStorage.isFrom == 'proposal') {
return this.$dialog
.confirm({
className: 'dialog-delete',
title: '提示',
message: '退出流程可能会丢失部分数据,是否确认退出?',
cancelButtonColor: '#E9332E',
confirmButtonColor: '#FFFFFF'
})
.then(() => {
this.$jump({
flag: 'h5',
extra: {
title: '建议书列表',
forbidSwipeBack: 1, //当前页面禁止右滑返回
url: location.origin + `/#/proposal/list`
},
routerInfo: {
path: `/proposal/list`,
type: '1'
}
})
})
.catch(() => {
return
})
} }
}, },
//获取已选产品列表 //获取已选产品列表
@@ -380,6 +426,21 @@ export default {
this.$toast(resultData.resultMessage) this.$toast(resultData.resultMessage)
} }
}, },
//编辑
editInsure(index,insuanceId){
let isProposal = localStorage.isFrom == 'proposal' ? true : false
if (isProposal) {
this.$jump({
flag: 'h5',
extra: {
url: location.origin + '/#/common/calculatePremium?proposalOrderNo='+this.$route.query.proposalOrderNo+'&insuanceId='+insuanceId
},
routerInfo: {
path: '/common/calculatePremium?proposalOrderNo='+this.$route.query.proposalOrderNo+'&insuanceId='+insuanceId
}
})
}
},
//下一步 //下一步
async nextStep() { async nextStep() {
if (!this.$route.query.salePageFlag) { if (!this.$route.query.salePageFlag) {
@@ -584,7 +645,7 @@ export default {
showTipForDoubleRecord() { showTipForDoubleRecord() {
//判断投保人年龄是否大于等于60岁 //判断投保人年龄是否大于等于60岁
let showFlag = false let showFlag = false
let age = utilsAge.getAge(this.appntDTO.birthday, new Date()) let age = this.appntDTO.birthday?utilsAge.getAge(this.appntDTO.birthday, new Date()):this.appntDTO.age
if (age >= 60) { if (age >= 60) {
this.chooseProducts.map(item => { this.chooseProducts.map(item => {
if (item.insuYearFlag == 'A' || (item.insuYearFlag == 'Y' && item.insuYear != '1')) { if (item.insuYearFlag == 'A' || (item.insuYearFlag == 'Y' && item.insuYear != '1')) {