From 55d777939bce471ab0e579dc8d2eb2f1d1928b79 Mon Sep 17 00:00:00 2001 From: zhouna Date: Thu, 26 Dec 2019 14:15:47 +0800 Subject: [PATCH] =?UTF-8?q?[FIX]=E6=8D=A2=E5=8D=A1=E6=B5=81=E7=A8=8B?= =?UTF-8?q?=E7=BC=93=E5=AD=98=E9=97=AE=E9=A2=98=E4=BC=98=E5=8C=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/ebiz/sale/AccountInformation.vue | 18 +++++---- src/views/ebiz/sale/AttachmentManagement.vue | 40 ++++++++++++-------- src/views/ebiz/sale/List.vue | 4 ++ 3 files changed, 39 insertions(+), 23 deletions(-) diff --git a/src/views/ebiz/sale/AccountInformation.vue b/src/views/ebiz/sale/AccountInformation.vue index 14e1d9005..1b651125d 100644 --- a/src/views/ebiz/sale/AccountInformation.vue +++ b/src/views/ebiz/sale/AccountInformation.vue @@ -391,15 +391,19 @@ export default { let that = this // 获取投被保人是否同一个人 - that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt - // 获取被保人信息 - that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')) - // 获取投保人信息 - that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo')) + if (localStorage.saleInsuredPersonInfo) { + that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt + // 获取被保人信息 + that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')) + } + if (localStorage.saleInsuredInfo) { + // 获取投保人信息 + that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo')) + // 默认是投保人名字 + that.name = this.saleInsuredInfo.name + } // 获取银行卡列表 that.getBankList() - // 默认是投保人名字 - that.name = this.saleInsuredInfo.name // 是否显示自动垫交 this.isAutoPay = localStorage.isAutoPay // 是否显示自动续保 diff --git a/src/views/ebiz/sale/AttachmentManagement.vue b/src/views/ebiz/sale/AttachmentManagement.vue index b09822690..90adf60ab 100644 --- a/src/views/ebiz/sale/AttachmentManagement.vue +++ b/src/views/ebiz/sale/AttachmentManagement.vue @@ -361,7 +361,7 @@ export default { }, created() { //如果是从编辑进来的 - if (this.$route.query.edit) { + if (this.$route.query.edit || localStorage.changeCard) { getOrderDetail({ orderNo: localStorage.orderNo }).then(res => { // console.log(res) if (res.result == 0) { @@ -386,17 +386,22 @@ export default { } let that = this // 投被保人是否同人 - that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt + if (localStorage.saleInsuredPersonInfo) { + that.relationToAppnt = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')).relationToAppnt + // 获取被保人信息 + that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')) + } // 获取订单号 that.orderNo = window.localStorage.getItem('orderNo') // 获取是投保人还是被保人 that.isAppant = window.localStorage.getItem('accountInformationRadio') // 数据字典获取 that.idType = DataDictionary.idType - // 获取被保人信息 - that.saleInsuredPersonInfo = JSON.parse(window.localStorage.getItem('saleInsuredPersonInfo')) + // 获取投保人信息 - that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo')) + if (localStorage.saleInsuredInfo) { + that.saleInsuredInfo = JSON.parse(window.localStorage.getItem('saleInsuredInfo')) + } // document.body.style.backgroundColor = '#fff' // 身份证正面 if (window.localStorage.getItem('imgfrontPath') != null) { @@ -886,16 +891,17 @@ export default { }, // 点击下一步 next() { + console.log(888) let that = this - this.$toast.loading({ - duration: 0, // 持续展示 toast + // this.$toast.loading({ + // duration: 0, // 持续展示 toast - forbidClick: true, // 禁用背景点击 + // forbidClick: true, // 禁用背景点击 - loadingType: 'spinner', + // loadingType: 'spinner', - message: '加载中……' - }) + // message: '加载中……' + // }) //注释双录提示 // let request = { // productList: JSON.parse(localStorage.chooseProductCodes), @@ -921,7 +927,7 @@ export default { orderDTO: { orderInfoDTO: { orderNo: window.localStorage.getItem('orderNo'), - productCode: this.$route.query.edit ? localStorage.productCode : JSON.parse(localStorage.trialList)[0].productCode + productCode: this.$route.query.edit || this.changeCard ? localStorage.productCode : JSON.parse(localStorage.trialList)[0].productCode }, appntDTO: { relationToInsured: that.saleInsuredPersonInfo.relationToAppnt @@ -934,10 +940,12 @@ export default { saveInformation(data).then(res => { if (res.result == '0') { this.$toast.clear() - window.localStorage.setItem('accountInfomation-bank', that.bank) - window.localStorage.setItem('accountInformationRadio', that.radio) - window.localStorage.setItem('accountInformation-isPaymentSelf', JSON.stringify(that.checked)) - window.localStorage.setItem('jumpFromSign', '') + if (!this.changeCard) { + window.localStorage.setItem('accountInfomation-bank', that.bank) + window.localStorage.setItem('accountInformationRadio', that.radio) + window.localStorage.setItem('accountInformation-isPaymentSelf', JSON.stringify(that.checked)) + window.localStorage.setItem('jumpFromSign', '') + } window.localStorage.removeItem('imgfront') window.localStorage.removeItem('imgBackPath') window.localStorage.removeItem('imgfrontPath') diff --git a/src/views/ebiz/sale/List.vue b/src/views/ebiz/sale/List.vue index bf64cf331..b348948ea 100644 --- a/src/views/ebiz/sale/List.vue +++ b/src/views/ebiz/sale/List.vue @@ -206,6 +206,10 @@ export default { changeCard(order) { let url = '' let orderStatus = order.orderInfoDTO.orderStatus + localStorage.orderNo = order.orderInfoDTO.orderNo + if (order.insuredDTOs[0].riskDTOLst[0]) { + localStorage.setItem('productCode', order.insuredDTOs[0].riskDTOLst[0].mainRiskCode) + } localStorage.setItem('changeCard', true) switch (orderStatus) { case '55': //账户信息页