From bce2c8743634085b5d2b5ddc6bd856eb6c6bcd0b Mon Sep 17 00:00:00 2001
From: liyuetong
Date: Fri, 5 Nov 2021 11:17:35 +0800
Subject: [PATCH 1/5] =?UTF-8?q?=E6=94=AF=E4=BB=98=E9=A1=B5=E9=9D=A2-?=
=?UTF-8?q?=E5=BE=AE=E4=BF=A1=EF=BC=8C=E7=82=B9=E5=87=BB=E3=80=90=E5=88=86?=
=?UTF-8?q?=E4=BA=AB=E3=80=91=E8=BF=9B=E8=A1=8C=E7=AD=BE=E7=BA=A6=E7=9A=84?=
=?UTF-8?q?=EF=BC=8C=E9=9C=80=E5=9C=A8=E5=AE=8C=E6=88=90=E7=AD=BE=E7=BA=A6?=
=?UTF-8?q?=E5=90=8E=EF=BC=8C=E6=9C=AA=E8=87=AA=E5=8A=A8=E5=BC=B9=E5=87=BA?=
=?UTF-8?q?=E5=88=86=E4=BA=AB=E6=A1=86=E8=80=8C=E7=9B=B4=E6=8E=A5=E8=BF=9B?=
=?UTF-8?q?=E5=85=A5=E4=BA=86=E6=94=B6=E9=93=B6=E5=8F=B0=E9=A1=B5=E9=9D=A2?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/ebiz/sale/PayMent.vue | 45 +++++++++++++++++++++++----------
1 file changed, 31 insertions(+), 14 deletions(-)
diff --git a/src/views/ebiz/sale/PayMent.vue b/src/views/ebiz/sale/PayMent.vue
index a96b7a96d..0587be56f 100644
--- a/src/views/ebiz/sale/PayMent.vue
+++ b/src/views/ebiz/sale/PayMent.vue
@@ -158,7 +158,8 @@ export default {
gotPayParam: false, // 是否已正确获取支付参数,
payStatus: '', // 接口返回的支付状态
isWeixin, // 是否为微信环境
- isLoading: false // 分享到微信后的页面loading
+ isLoading: false, // 分享到微信后的页面loading
+ isShare:'' //0是点击分享 1是点击支付
}
},
created() {
@@ -263,6 +264,7 @@ export default {
})
}
// signFlag 是否完成签约
+ this.isShare = 1
let signFlag = await this.checkBankCardSign()
if (signFlag) {
const res = await payFlag({ orderNo: this.orderNo })
@@ -402,19 +404,20 @@ export default {
},
async share() {
// signFlag 是否完成签约
+ this.isShare = 0
let signFlag = await this.checkBankCardSign()
- if (signFlag) {
- let shareName = this.underWriteData.appntName
- EWebBridge.webCallAppInJs('bridge', {
- flag: 'share',
- extra: {
- title: `国富人寿电子投保单(${shareName})付款`,
- content: '付款进行',
- url: location.origin + '/#/sale/payMent?orderNo=' + localStorage.orderNo + '&token=' + localStorage.token,
- img: this.$assetsUrl + 'images/logo.png'
- }
- })
- }
+ // if (signFlag) {
+ // let shareName = this.underWriteData.appntName
+ // EWebBridge.webCallAppInJs('bridge', {
+ // flag: 'share',
+ // extra: {
+ // title: `国富人寿电子投保单(${shareName})付款`,
+ // content: '付款进行',
+ // url: location.origin + '/#/sale/payMent?orderNo=' + localStorage.orderNo + '&token=' + localStorage.token,
+ // img: this.$assetsUrl + 'images/logo.png'
+ // }
+ // })
+ // }
},
bankSignJump(shortUrl){
@@ -594,7 +597,21 @@ export default {
this.verfyCode = ''
let data = res.content
if (data.result == '0') {
- this.getAcceptInsurance()
+ this.show = false
+ if(this.isShare == 1){
+ this.getAcceptInsurance()
+ }else if(this.isShare == 0){
+ let shareName = this.underWriteData.appntName
+ EWebBridge.webCallAppInJs('bridge', {
+ flag: 'share',
+ extra: {
+ title: `国富人寿电子投保单(${shareName})付款`,
+ content: '付款进行',
+ url: location.origin + '/#/sale/payMent?orderNo=' + localStorage.orderNo + '&token=' + localStorage.token,
+ img: this.$assetsUrl + 'images/logo.png'
+ }
+ })
+ }
}else{
// 签约失败
const info = '亲,您当前银行卡账户续期签约失败,\n原因:' + data.resultMessage
From 74a1d7a2583c8e7310b10a5e559b9e0f1fdd2c63 Mon Sep 17 00:00:00 2001
From: liyuetong
Date: Fri, 5 Nov 2021 14:08:34 +0800
Subject: [PATCH 2/5] =?UTF-8?q?=E6=94=AF=E4=BB=98=E9=A1=B5=E9=9D=A2-?=
=?UTF-8?q?=E6=9F=A5=E8=AF=A2=E9=93=B6=E8=A1=8C=E5=8D=A1=E7=AD=BE=E7=BA=A6?=
=?UTF-8?q?=EF=BC=8C=E7=82=B9=E5=87=BB=E7=A1=AE=E8=AE=A4=E5=90=8E=E5=8A=A0?=
=?UTF-8?q?loading=EF=BC=8C=E8=AF=B7=E6=B1=82=E6=8E=A5=E5=8F=A3=E6=88=90?=
=?UTF-8?q?=E5=8A=9F=E5=90=8E=E9=9A=90=E8=97=8Floading?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/ebiz/sale/PayMent.vue | 32 ++++++++++++++++++++------------
1 file changed, 20 insertions(+), 12 deletions(-)
diff --git a/src/views/ebiz/sale/PayMent.vue b/src/views/ebiz/sale/PayMent.vue
index 0587be56f..3a86f5ea5 100644
--- a/src/views/ebiz/sale/PayMent.vue
+++ b/src/views/ebiz/sale/PayMent.vue
@@ -406,18 +406,18 @@ export default {
// signFlag 是否完成签约
this.isShare = 0
let signFlag = await this.checkBankCardSign()
- // if (signFlag) {
- // let shareName = this.underWriteData.appntName
- // EWebBridge.webCallAppInJs('bridge', {
- // flag: 'share',
- // extra: {
- // title: `国富人寿电子投保单(${shareName})付款`,
- // content: '付款进行',
- // url: location.origin + '/#/sale/payMent?orderNo=' + localStorage.orderNo + '&token=' + localStorage.token,
- // img: this.$assetsUrl + 'images/logo.png'
- // }
- // })
- // }
+ if (signFlag) {
+ let shareName = this.underWriteData.appntName
+ EWebBridge.webCallAppInJs('bridge', {
+ flag: 'share',
+ extra: {
+ title: `国富人寿电子投保单(${shareName})付款`,
+ content: '付款进行',
+ url: location.origin + '/#/sale/payMent?orderNo=' + localStorage.orderNo + '&token=' + localStorage.token,
+ img: this.$assetsUrl + 'images/logo.png'
+ }
+ })
+ }
},
bankSignJump(shortUrl){
@@ -580,6 +580,12 @@ export default {
},
// 验证码弹框--签约确认
authConfirm(){
+ this.$toast.loading({
+ duration: 0, // 持续展示 toast
+ forbidClick: true, // 禁用背景点击
+ loadingType: 'spinner',
+ message: '加载中……'
+ })
let data = {
rdSeq:this.rdSeq,
verfyCode:this.verfyCode,
@@ -597,6 +603,7 @@ export default {
this.verfyCode = ''
let data = res.content
if (data.result == '0') {
+ this.$toast.clear()
this.show = false
if(this.isShare == 1){
this.getAcceptInsurance()
@@ -613,6 +620,7 @@ export default {
})
}
}else{
+ this.$toast.clear()
// 签约失败
const info = '亲,您当前银行卡账户续期签约失败,\n原因:' + data.resultMessage
Dialog.confirm({
From 95e8858db7e834d9a4a4dddde1c151f72f555c08 Mon Sep 17 00:00:00 2001
From: liyuetong
Date: Fri, 5 Nov 2021 14:15:00 +0800
Subject: [PATCH 3/5] =?UTF-8?q?Android=E8=8E=B7=E5=8F=96token-=E5=8A=A0?=
=?UTF-8?q?=E6=B3=A8=E9=87=8A?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/assets/js/utils/request.js | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/assets/js/utils/request.js b/src/assets/js/utils/request.js
index 757eeaff0..87a991c3a 100644
--- a/src/assets/js/utils/request.js
+++ b/src/assets/js/utils/request.js
@@ -172,6 +172,7 @@ service.interceptors.request.use(
let u = navigator.userAgent;
let isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //判断是否是 android终端
if(isAndroid){
+ console.log(window.Android.getToken(),'Android获取token')
CacheUtils.setLocItem('token', JSON.parse(window.Android.getToken()))
}else{
const res = await EWebBridge.webCallAppInJs('getToken')
From 4b2f61f1260c358ce42cbd243d4a15282a3de8fe Mon Sep 17 00:00:00 2001
From: liyuetong
Date: Fri, 5 Nov 2021 15:05:55 +0800
Subject: [PATCH 4/5] =?UTF-8?q?=E5=BE=AE=E4=BF=A1=E6=94=AF=E4=BB=98?=
=?UTF-8?q?=E9=A1=B5=E9=9D=A2=E6=97=A0=E6=B3=95=E6=89=93=E5=BC=80=EF=BC=8C?=
=?UTF-8?q?=E5=A6=82=E6=9E=9C=E6=98=AF=E5=BE=AE=E4=BF=A1=E7=9B=B4=E6=8E=A5?=
=?UTF-8?q?=E8=B0=83=E6=94=AF=E4=BB=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/ebiz/sale/PayMent.vue | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)
diff --git a/src/views/ebiz/sale/PayMent.vue b/src/views/ebiz/sale/PayMent.vue
index 3a86f5ea5..65b251723 100644
--- a/src/views/ebiz/sale/PayMent.vue
+++ b/src/views/ebiz/sale/PayMent.vue
@@ -197,10 +197,23 @@ export default {
let orderNo = this.$route.query.orderNo
localStorage.token = token
localStorage.orderNo = orderNo
- this.payMent()
+ // this.twounderWrite().then
+ this.payMentWx(orderNo) //直接调支付
}
},
methods: {
+ async payMentWx(orderNo){
+ const res = await payFlag({ orderNo: orderNo })
+ console.dir(res)
+ if (res.content.payFlag == 'Y') {
+ this.getAcceptInsurance()
+ } else {
+ this.$toast(res.resultMessage)
+ setTimeout(() => {
+ this.$router.push({ path: '/sale/payResultFail' })
+ }, 2000)
+ }
+ },
getAcceptInsurance() {
let that = this
let data = {
@@ -326,6 +339,7 @@ export default {
}
let mobile = res.orderDTO.appntDTO.mobile
this.encyCustomerMobile = mobile.slice(0, 3) + '****' + mobile.slice(-4)
+ console.log(this.encyCustomerMobil,'手机号')
} else {
let underWriteData = {
accountName: '',
From 3a9c7000e658788c5f86ce5e0d4a6e0110b7d9d3 Mon Sep 17 00:00:00 2001
From: liyuetong
Date: Fri, 5 Nov 2021 15:45:47 +0800
Subject: [PATCH 5/5] =?UTF-8?q?=E7=9F=AD=E4=BF=A1=E9=AA=8C=E8=AF=81?=
=?UTF-8?q?=E7=A0=81=E5=B7=B2=E5=8F=91=E9=80=81=E8=87=B3=E6=82=A8=E7=9A=84?=
=?UTF-8?q?=E6=89=8B=E6=9C=BA=E5=8F=B7=EF=BC=8C=E6=89=8B=E6=9C=BA=E5=8F=B7?=
=?UTF-8?q?=E4=B8=8D=E6=98=BE=E7=A4=BA=E9=97=AE=E9=A2=98?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/views/ebiz/sale/PayMent.vue | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/src/views/ebiz/sale/PayMent.vue b/src/views/ebiz/sale/PayMent.vue
index 65b251723..877566202 100644
--- a/src/views/ebiz/sale/PayMent.vue
+++ b/src/views/ebiz/sale/PayMent.vue
@@ -194,10 +194,10 @@ export default {
console.log('--自核结果--支付信息:', JSON.stringify(this.underWriteData))
} else {
let token = this.$route.query.token
+ this.orderNo = this.$route.query.orderNo
let orderNo = this.$route.query.orderNo
localStorage.token = token
localStorage.orderNo = orderNo
- // this.twounderWrite().then
this.payMentWx(orderNo) //直接调支付
}
},
@@ -339,7 +339,7 @@ export default {
}
let mobile = res.orderDTO.appntDTO.mobile
this.encyCustomerMobile = mobile.slice(0, 3) + '****' + mobile.slice(-4)
- console.log(this.encyCustomerMobil,'手机号')
+ console.log(this.encyCustomerMobil,'手机号2')
} else {
let underWriteData = {
accountName: '',
@@ -392,6 +392,9 @@ export default {
if (res.result == '0') {
this.$toast.clear()
let riskDTOLst = res.orderDTO.insuredDTOs[0].riskDTOLst[0];
+ let mobile = res.orderDTO.appntDTO.mobile
+ this.encyCustomerMobile = mobile.slice(0, 3) + '****' + mobile.slice(-4)
+ console.log(this.encyCustomerMobil,'手机号1')
// 判断是否为长期险 短期险不校验签约
if ((riskDTOLst.insuYearFlag == 'Y' && riskDTOLst.insuYear > 1) || riskDTOLst.insuYearFlag == 'A') {
this.$CacheUtils.setLocItem('isLongInsuranceFlag', "Y");