feat(pay): merge pay
This commit is contained in:
parent
ee01aba367
commit
d2db18d57e
|
@ -30,10 +30,10 @@
|
|||
<u-collapse-item
|
||||
name="1"
|
||||
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="" />
|
||||
<view>{{ '钱包支付' }}</view>
|
||||
</view>
|
||||
|
@ -169,7 +169,7 @@
|
|||
</view>
|
||||
</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">
|
||||
<img src="@/static/images/under_pay.png" alt="" />
|
||||
<view>{{ '在线支付' }}</view>
|
||||
|
@ -183,7 +183,12 @@
|
|||
<view>{{ '宝付微信支付' }}</view>
|
||||
</view>
|
||||
<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-group>
|
||||
</view>
|
||||
|
@ -196,7 +201,12 @@
|
|||
<view>{{ '宝付微信扫码' }}</view>
|
||||
</view>
|
||||
<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-group>
|
||||
</view>
|
||||
|
@ -209,7 +219,12 @@
|
|||
<view>{{ '汇付微信支付' }}</view>
|
||||
</view>
|
||||
<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-group>
|
||||
</view>
|
||||
|
@ -223,7 +238,12 @@
|
|||
<view>{{ '微信支付' }}</view>
|
||||
</view>
|
||||
<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-group>
|
||||
</view>
|
||||
|
@ -234,7 +254,12 @@
|
|||
<view>{{ '支付宝支付' }}</view>
|
||||
</view>
|
||||
<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-group>
|
||||
</view>
|
||||
|
@ -263,7 +288,7 @@
|
|||
activeColor="red"
|
||||
size="14"
|
||||
label=""
|
||||
:name="'hf' + index"
|
||||
:name="PAY_TYPE.HUI_FU_BANK_CARD + index"
|
||||
>
|
||||
</u-radio>
|
||||
</u-radio-group>
|
||||
|
@ -283,7 +308,12 @@
|
|||
<view>通联微信支付</view>
|
||||
</view>
|
||||
<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-group>
|
||||
</view>
|
||||
|
@ -310,7 +340,7 @@
|
|||
activeColor="red"
|
||||
size="14"
|
||||
label=""
|
||||
:name="'jd' + index"
|
||||
:name="PAY_TYPE.JING_DONG_BANK_CARD + index"
|
||||
>
|
||||
</u-radio>
|
||||
</u-radio-group>
|
||||
|
@ -362,7 +392,7 @@
|
|||
activeColor="red"
|
||||
size="14"
|
||||
label=""
|
||||
:name="'tl' + index"
|
||||
:name="PAY_TYPE.TONG_LIAN_BANK_CARD + index"
|
||||
>
|
||||
</u-radio>
|
||||
</u-radio-group>
|
||||
|
@ -1136,30 +1166,11 @@ export default {
|
|||
})
|
||||
}
|
||||
} 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 {
|
||||
api.generate().then(res => {
|
||||
uni.setStorageSync('mToken', res.msg)
|
||||
})
|
||||
this.isBank = ''
|
||||
this.isPw = true
|
||||
}
|
||||
api.generate().then(res => {
|
||||
uni.setStorageSync('mToken', res.msg)
|
||||
})
|
||||
this.isBank = ''
|
||||
this.isPw = true
|
||||
}
|
||||
},
|
||||
scanPayBfWx(val) {
|
||||
|
@ -1221,25 +1232,19 @@ export default {
|
|||
businessCode: this.orderCode,
|
||||
extParam: extParamBase64,
|
||||
}
|
||||
} else {
|
||||
params = {
|
||||
businessType: this.businessType, //订单类型充值
|
||||
businessCode: this.orderCode,
|
||||
payChannel: val,
|
||||
payType: 2,
|
||||
appletFlag: 0,
|
||||
}
|
||||
}
|
||||
api.unifiedorder(params).then(res => {
|
||||
let url =
|
||||
'https://clooud1-5g23d3je04dda65b-1326540601.tcloudbaseapp.com/jump_mp.html?sign=20f03b022bc39e837056bdbe475632c8&t=1715569339&state=' +
|
||||
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)
|
||||
api.unifiedorder(params).then(res => {
|
||||
if (res.code === 200) {
|
||||
resolve(res.data)
|
||||
this.checkPayStatus(params)
|
||||
} else {
|
||||
uni.showToast({
|
||||
title: res.msg,
|
||||
icon: 'none',
|
||||
})
|
||||
reject(res.msg)
|
||||
}
|
||||
})
|
||||
})
|
||||
this.checkPayStatus(params)
|
||||
},
|
||||
drawQrcode(text) {
|
||||
let that = this
|
||||
|
|
Loading…
Reference in New Issue