完善转账和充值

This commit is contained in:
唐明明
2022-06-10 12:35:24 +08:00
parent f4a2fa5160
commit d7cd566e57
7 changed files with 4352 additions and 4311 deletions

View File

@@ -80,7 +80,6 @@ const submitTransfer = data => {
})
}
export {
dt,
recharge,

View File

@@ -93,10 +93,12 @@
provider: 'wxpay',
orderInfo: JSON.parse(res),
success: res => {
console.log(res)
uni.redirectTo({
url: './results?type=recharge'
})
},
fail(err) {
let showToast = err.message
let showToast = err.errMsg
if(err.errMsg === 'requestPayment:fail [payment微信:-2]User canceled'){
showToast = '充值被取消'
}

View File

@@ -2,9 +2,9 @@
<view>
<view class="vertical results">
<uni-icons type="checkbox-filled" size="88" color="#34CE98"></uni-icons>
<view class="title">交易已提交</view>
<view class="sub-title">预计10秒内到账可在交易记录中查询以实际到账时间为准</view>
<view class="hash">
<view class="title">{{type !== 'recharge' ? '转账交易已提交' : '充值信息已提交'}}</view>
<view class="sub-title">预计10秒内到账{{type !== 'recharge' ? '可在DT积分账户交易记录中查询以实际到账时间为准' : '可在DT积分账户交易记录中查询如充值失败充值金额原路退还'}}</view>
<view class="hash" v-if="type !== 'recharge'">
<view class="hash-title">交易哈希</view>
<view class="hash-text">{{hash}}</view>
</view>
@@ -17,11 +17,20 @@
export default {
data() {
return {
type: 'recharge',
hash: ''
};
},
onLoad(e){
this.hash = e.hash
this.type = e.type
if(e.type === 'recharge'){
uni.setNavigationBarTitle({
title: '充值结果'
})
}
if(e.hash){
this.hash = e.hash
}
},
methods:{
navBack(){

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -19043,28 +19043,30 @@ var render = function() {
[
_c("uni-icons", { attrs: { _i: 2 } }),
_c("uni-view", { staticClass: _vm._$g(3, "sc"), attrs: { _i: 3 } }, [
_vm._v("交易已提交")
_vm._v(_vm._$g(3, "t0-0"))
]),
_c("uni-view", { staticClass: _vm._$g(4, "sc"), attrs: { _i: 4 } }, [
_vm._v("预计10秒内到账可在交易记录中查询,以实际到账时间为准")
_vm._v("预计10秒内到账" + _vm._$g(4, "t0-0"))
]),
_c(
"uni-view",
{ staticClass: _vm._$g(5, "sc"), attrs: { _i: 5 } },
[
_c(
_vm._$g(5, "i")
? _c(
"uni-view",
{ staticClass: _vm._$g(6, "sc"), attrs: { _i: 6 } },
[_vm._v("交易哈希")]
),
_c(
"uni-view",
{ staticClass: _vm._$g(7, "sc"), attrs: { _i: 7 } },
[_vm._v(_vm._$g(7, "t0-0"))]
{ staticClass: _vm._$g(5, "sc"), attrs: { _i: 5 } },
[
_c(
"uni-view",
{ staticClass: _vm._$g(6, "sc"), attrs: { _i: 6 } },
[_vm._v("交易哈希")]
),
_c(
"uni-view",
{ staticClass: _vm._$g(7, "sc"), attrs: { _i: 7 } },
[_vm._v(_vm._$g(7, "t0-0"))]
)
],
1
)
],
1
),
: _vm._e(),
_c(
"v-uni-button",
{

File diff suppressed because one or more lines are too long