feat(pay): merge pay
This commit is contained in:
parent
ee01aba367
commit
d2db18d57e
|
@ -30,10 +30,10 @@
|
||||||
<u-collapse-item
|
<u-collapse-item
|
||||||
name="1"
|
name="1"
|
||||||
v-if="
|
v-if="
|
||||||
!isRecharge && !isShare & (userInfo.memberCode != 'CN68880628')
|
!isRecharge && !isShare & (userInfo.memberCode != 'BD68880628')
|
||||||
"
|
"
|
||||||
>
|
>
|
||||||
<view slot="title" BD68880628 class="pf">
|
<view slot="title" class="pf">
|
||||||
<img src="@/static/images/yhkzf.jpg" alt="" />
|
<img src="@/static/images/yhkzf.jpg" alt="" />
|
||||||
<view>{{ '钱包支付' }}</view>
|
<view>{{ '钱包支付' }}</view>
|
||||||
</view>
|
</view>
|
||||||
|
@ -169,7 +169,7 @@
|
||||||
</view>
|
</view>
|
||||||
</u-collapse-item>
|
</u-collapse-item>
|
||||||
<!-- 暂时隐藏在线支付 -->
|
<!-- 暂时隐藏在线支付 -->
|
||||||
<u-collapse-item name="2" v-if="onlinePay && false">
|
<u-collapse-item name="2" v-if="onlinePay">
|
||||||
<view slot="title" class="pf">
|
<view slot="title" class="pf">
|
||||||
<img src="@/static/images/under_pay.png" alt="" />
|
<img src="@/static/images/under_pay.png" alt="" />
|
||||||
<view>{{ '在线支付' }}</view>
|
<view>{{ '在线支付' }}</view>
|
||||||
|
@ -183,7 +183,12 @@
|
||||||
<view>{{ '宝付微信支付' }}</view>
|
<view>{{ '宝付微信支付' }}</view>
|
||||||
</view>
|
</view>
|
||||||
<u-radio-group v-model="whatPay">
|
<u-radio-group v-model="whatPay">
|
||||||
<u-radio activeColor="red" size="14" label="" :name="11">
|
<u-radio
|
||||||
|
activeColor="red"
|
||||||
|
size="14"
|
||||||
|
label=""
|
||||||
|
:name="PAY_TYPE.BAO_FU_WECHAT"
|
||||||
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
@ -196,7 +201,12 @@
|
||||||
<view>{{ '宝付微信扫码' }}</view>
|
<view>{{ '宝付微信扫码' }}</view>
|
||||||
</view>
|
</view>
|
||||||
<u-radio-group v-model="whatPay">
|
<u-radio-group v-model="whatPay">
|
||||||
<u-radio activeColor="red" size="14" label="" :name="12">
|
<u-radio
|
||||||
|
activeColor="red"
|
||||||
|
size="14"
|
||||||
|
label=""
|
||||||
|
:name="PAY_TYPE.BAO_FU_WECHAT_SCAN"
|
||||||
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
@ -209,7 +219,12 @@
|
||||||
<view>{{ '汇付微信支付' }}</view>
|
<view>{{ '汇付微信支付' }}</view>
|
||||||
</view>
|
</view>
|
||||||
<u-radio-group v-model="whatPay">
|
<u-radio-group v-model="whatPay">
|
||||||
<u-radio activeColor="red" size="14" label="" :name="13">
|
<u-radio
|
||||||
|
activeColor="red"
|
||||||
|
size="14"
|
||||||
|
label=""
|
||||||
|
:name="PAY_TYPE.HUI_FU_WECHAT"
|
||||||
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
@ -223,7 +238,12 @@
|
||||||
<view>{{ '微信支付' }}</view>
|
<view>{{ '微信支付' }}</view>
|
||||||
</view>
|
</view>
|
||||||
<u-radio-group v-model="whatPay">
|
<u-radio-group v-model="whatPay">
|
||||||
<u-radio activeColor="red" size="14" label="" :name="73">
|
<u-radio
|
||||||
|
activeColor="red"
|
||||||
|
size="14"
|
||||||
|
label=""
|
||||||
|
:name="PAY_TYPE.WECHAT_PAY"
|
||||||
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
@ -234,7 +254,12 @@
|
||||||
<view>{{ '支付宝支付' }}</view>
|
<view>{{ '支付宝支付' }}</view>
|
||||||
</view>
|
</view>
|
||||||
<u-radio-group v-model="whatPay">
|
<u-radio-group v-model="whatPay">
|
||||||
<u-radio activeColor="red" size="14" label="" :name="74">
|
<u-radio
|
||||||
|
activeColor="red"
|
||||||
|
size="14"
|
||||||
|
label=""
|
||||||
|
:name="PAY_TYPE.ALI_PAY"
|
||||||
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
@ -263,7 +288,7 @@
|
||||||
activeColor="red"
|
activeColor="red"
|
||||||
size="14"
|
size="14"
|
||||||
label=""
|
label=""
|
||||||
:name="'hf' + index"
|
:name="PAY_TYPE.HUI_FU_BANK_CARD + index"
|
||||||
>
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
|
@ -283,7 +308,12 @@
|
||||||
<view>通联微信支付</view>
|
<view>通联微信支付</view>
|
||||||
</view>
|
</view>
|
||||||
<u-radio-group v-model="whatPay">
|
<u-radio-group v-model="whatPay">
|
||||||
<u-radio activeColor="red" size="14" label="" :name="32">
|
<u-radio
|
||||||
|
activeColor="red"
|
||||||
|
size="14"
|
||||||
|
label=""
|
||||||
|
:name="PAY_TYPE.TONG_LIAN_WECHAT"
|
||||||
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
@ -310,7 +340,7 @@
|
||||||
activeColor="red"
|
activeColor="red"
|
||||||
size="14"
|
size="14"
|
||||||
label=""
|
label=""
|
||||||
:name="'jd' + index"
|
:name="PAY_TYPE.JING_DONG_BANK_CARD + index"
|
||||||
>
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
|
@ -362,7 +392,7 @@
|
||||||
activeColor="red"
|
activeColor="red"
|
||||||
size="14"
|
size="14"
|
||||||
label=""
|
label=""
|
||||||
:name="'tl' + index"
|
:name="PAY_TYPE.TONG_LIAN_BANK_CARD + index"
|
||||||
>
|
>
|
||||||
</u-radio>
|
</u-radio>
|
||||||
</u-radio-group>
|
</u-radio-group>
|
||||||
|
@ -1135,24 +1165,6 @@ export default {
|
||||||
this.checkPayStatus(params)
|
this.checkPayStatus(params)
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
if (cz) {
|
|
||||||
//充值
|
|
||||||
api
|
|
||||||
.preCharge({
|
|
||||||
rechargeAmount: this.czJe,
|
|
||||||
})
|
|
||||||
.then(res => {
|
|
||||||
this.paramsPost = res.data
|
|
||||||
this.orderCode = res.orderCode
|
|
||||||
if (this.whatPay == 12) {
|
|
||||||
this.scanPayBfWx(5)
|
|
||||||
} else if (this.whatPay == 13) {
|
|
||||||
this.scanPayBfWx(6)
|
|
||||||
}
|
|
||||||
})
|
|
||||||
this.isBank = ''
|
|
||||||
this.isPw = true
|
|
||||||
} else {
|
} else {
|
||||||
api.generate().then(res => {
|
api.generate().then(res => {
|
||||||
uni.setStorageSync('mToken', res.msg)
|
uni.setStorageSync('mToken', res.msg)
|
||||||
|
@ -1160,7 +1172,6 @@ export default {
|
||||||
this.isBank = ''
|
this.isBank = ''
|
||||||
this.isPw = true
|
this.isPw = true
|
||||||
}
|
}
|
||||||
}
|
|
||||||
},
|
},
|
||||||
scanPayBfWx(val) {
|
scanPayBfWx(val) {
|
||||||
let params
|
let params
|
||||||
|
@ -1221,25 +1232,19 @@ export default {
|
||||||
businessCode: this.orderCode,
|
businessCode: this.orderCode,
|
||||||
extParam: extParamBase64,
|
extParam: extParamBase64,
|
||||||
}
|
}
|
||||||
} else {
|
|
||||||
params = {
|
|
||||||
businessType: this.businessType, //订单类型充值
|
|
||||||
businessCode: this.orderCode,
|
|
||||||
payChannel: val,
|
|
||||||
payType: 2,
|
|
||||||
appletFlag: 0,
|
|
||||||
}
|
|
||||||
}
|
|
||||||
api.unifiedorder(params).then(res => {
|
api.unifiedorder(params).then(res => {
|
||||||
let url =
|
if (res.code === 200) {
|
||||||
'https://clooud1-5g23d3je04dda65b-1326540601.tcloudbaseapp.com/jump_mp.html?sign=20f03b022bc39e837056bdbe475632c8&t=1715569339&state=' +
|
resolve(res.data)
|
||||||
res.data +
|
|
||||||
'&payment=0'
|
|
||||||
// https://clooud1-5g23d3je04dda65b-1326540601.tcloudbaseapp.com/jump_mp.html?sign=812bf9ab54292b1fb7161a3a6f7fa0f6&t=1715570889&state=' +
|
|
||||||
// res.data + '&payment=0'
|
|
||||||
window.open(url)
|
|
||||||
})
|
|
||||||
this.checkPayStatus(params)
|
this.checkPayStatus(params)
|
||||||
|
} else {
|
||||||
|
uni.showToast({
|
||||||
|
title: res.msg,
|
||||||
|
icon: 'none',
|
||||||
|
})
|
||||||
|
reject(res.msg)
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
},
|
},
|
||||||
drawQrcode(text) {
|
drawQrcode(text) {
|
||||||
let that = this
|
let that = this
|
||||||
|
|
Loading…
Reference in New Issue