no message
This commit is contained in:
92
pages/pay-fail/index.js
Normal file
92
pages/pay-fail/index.js
Normal file
@@ -0,0 +1,92 @@
|
||||
var e = require("../../common/vendor.js"),
|
||||
r = require("../../hooks/onMounted.js"),
|
||||
n = require("../../hooks/onShareAppMessage.js"),
|
||||
o = require("../../service/index.js"),
|
||||
i = require("../../utils/navigate.js"),
|
||||
u = require("../../utils/util.js"),
|
||||
a = require("../../enums/index.js"),
|
||||
t = require("../../utils/common.js");
|
||||
require("../../hooks/useState.js"),
|
||||
require("../../store/app/index.js"),
|
||||
require("../../data/index.js"),
|
||||
require("../../config/index.js"),
|
||||
require("../../constant/index.js"),
|
||||
require("../../utils/request.js"),
|
||||
Math || (e.unref(d) + e.unref(c) + e.unref(s))();
|
||||
var s = function () {
|
||||
return "../../components/popup-pay-again/index.js";
|
||||
},
|
||||
d = function () {
|
||||
return "../../components/float-help/index.js";
|
||||
},
|
||||
c = function () {
|
||||
return "../../components/float-share/index.js";
|
||||
},
|
||||
p = {
|
||||
__name: "index",
|
||||
setup: function (s) {
|
||||
var d = e.ref(!0),
|
||||
c = e.ref(""),
|
||||
p = e.ref({}),
|
||||
f = e.ref(!1),
|
||||
l = function () {
|
||||
i.redirectTo({ url: "/pages/order-list-mine/index" });
|
||||
},
|
||||
v = function () {
|
||||
q(a.PayMethodEnum.WECHAT_PAY);
|
||||
},
|
||||
h = function () {
|
||||
f.value = !1;
|
||||
},
|
||||
j = function (e) {
|
||||
q(e), (f.value = !1);
|
||||
},
|
||||
q = function (e) {
|
||||
u.showLoading("支付中"),
|
||||
o
|
||||
.payOrderAgain({ payMethod: e, order_no: c.value })
|
||||
.then(function (r) {
|
||||
t.payForOrder({ payMethod: e, data: r })
|
||||
.then(function (e) {
|
||||
var r = e.orderNo;
|
||||
i.redirectTo({
|
||||
url: "/pages/pay-success/index",
|
||||
params: { orderNo: r },
|
||||
});
|
||||
})
|
||||
.catch(function (e) {
|
||||
var r = e.orderNo;
|
||||
i.redirectTo({
|
||||
url: "/pages/pay-fail/index",
|
||||
params: { orderNo: r },
|
||||
});
|
||||
});
|
||||
});
|
||||
};
|
||||
return (
|
||||
r.onMounted(function (e) {
|
||||
(c.value = e.orderNo),
|
||||
o.getOrderDetail({ order_no: e.orderNo }).then(function (e) {
|
||||
(p.value = e), (d.value = !1), u.hideLoading();
|
||||
});
|
||||
}),
|
||||
n.onShareAppMessage(),
|
||||
function (r, n) {
|
||||
return e.e(
|
||||
{ a: !d.value },
|
||||
d.value
|
||||
? {}
|
||||
: {
|
||||
b: e.o(v),
|
||||
c: e.o(l),
|
||||
d: e.o(h),
|
||||
e: e.o(j),
|
||||
f: e.p({ visible: f.value }),
|
||||
}
|
||||
);
|
||||
}
|
||||
);
|
||||
},
|
||||
},
|
||||
f = e._export_sfc(p, [["__scopeId", "data-v-cb7a366a"]]);
|
||||
(p.__runtimeHooks = 2), wx.createPage(f);
|
||||
8
pages/pay-fail/index.json
Normal file
8
pages/pay-fail/index.json
Normal file
@@ -0,0 +1,8 @@
|
||||
{
|
||||
"navigationBarTitleText": "支付失败",
|
||||
"usingComponents": {
|
||||
"popup-pay-again": "../../components/popup-pay-again/index",
|
||||
"float-help": "../../components/float-help/index",
|
||||
"float-share": "../../components/float-share/index"
|
||||
}
|
||||
}
|
||||
45
pages/pay-fail/index.wxml
Normal file
45
pages/pay-fail/index.wxml
Normal file
@@ -0,0 +1,45 @@
|
||||
<view class="content data-v-cb7a366a" wx:if="{{a}}">
|
||||
<image
|
||||
class="pic data-v-cb7a366a"
|
||||
src="/static/images/pic_pay_fail.png"
|
||||
></image>
|
||||
<view class="pay-status data-v-cb7a366a">支付失败</view>
|
||||
<view class="tips data-v-cb7a366a">很遗憾,您没有支付成功</view>
|
||||
<view class="button-content data-v-cb7a366a">
|
||||
<button
|
||||
bindtap="{{b}}"
|
||||
class="button type1 data-v-cb7a366a"
|
||||
hoverClass="default-hover-class"
|
||||
hoverStayTime="100"
|
||||
>
|
||||
重新支付
|
||||
</button>
|
||||
<button
|
||||
bindtap="{{c}}"
|
||||
class="button type3 data-v-cb7a366a"
|
||||
hoverClass="default-hover-class"
|
||||
hoverStayTime="100"
|
||||
>
|
||||
查看订单
|
||||
</button>
|
||||
</view>
|
||||
<float-help
|
||||
bind:__l="__l"
|
||||
class="data-v-cb7a366a"
|
||||
uI="cb7a366a-0"
|
||||
></float-help>
|
||||
<float-share
|
||||
bind:__l="__l"
|
||||
class="data-v-cb7a366a"
|
||||
uI="cb7a366a-1"
|
||||
></float-share>
|
||||
<popup-pay-again
|
||||
bind:__l="__l"
|
||||
bindclose="{{d}}"
|
||||
bindconfirm="{{e}}"
|
||||
class="data-v-cb7a366a"
|
||||
uI="cb7a366a-2"
|
||||
uP="{{f}}"
|
||||
wx:if="{{f}}"
|
||||
></popup-pay-again>
|
||||
</view>
|
||||
68
pages/pay-fail/index.wxss
Normal file
68
pages/pay-fail/index.wxss
Normal file
@@ -0,0 +1,68 @@
|
||||
page {
|
||||
background-color: #fff;
|
||||
overflow: visible !important;
|
||||
}
|
||||
.content.data-v-cb7a366a {
|
||||
align-items: center;
|
||||
display: -webkit-flex;
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
padding: 60rpx;
|
||||
}
|
||||
.content .pic.data-v-cb7a366a {
|
||||
height: 207rpx;
|
||||
margin-top: 120rpx;
|
||||
width: 319rpx;
|
||||
}
|
||||
.content .pay-status.data-v-cb7a366a {
|
||||
font-size: 42rpx;
|
||||
font-weight: 700;
|
||||
margin-top: 100rpx;
|
||||
}
|
||||
.content .tips.data-v-cb7a366a {
|
||||
color: #5e5e6b;
|
||||
font-size: 28rpx;
|
||||
line-height: 44rpx;
|
||||
margin-top: 40rpx;
|
||||
padding: 0 20rpx;
|
||||
}
|
||||
.content .view-report.data-v-cb7a366a {
|
||||
color: #1f68e9;
|
||||
font-size: 32rpx;
|
||||
font-weight: 700;
|
||||
margin-top: 150rpx;
|
||||
}
|
||||
.content .button-content.data-v-cb7a366a {
|
||||
padding: 0 20rpx;
|
||||
width: 100%;
|
||||
}
|
||||
.content .button-content .button.data-v-cb7a366a {
|
||||
background-color: #fff;
|
||||
border-radius: 100rpx;
|
||||
font-size: 32rpx;
|
||||
height: 90rpx;
|
||||
line-height: 90rpx;
|
||||
padding: 0;
|
||||
text-align: center;
|
||||
width: 100%;
|
||||
}
|
||||
.content .button-content .button.type1.data-v-cb7a366a {
|
||||
background-color: #1f68e9;
|
||||
color: #fff;
|
||||
margin-top: 60rpx;
|
||||
}
|
||||
.content .button-content .button.type2.data-v-cb7a366a {
|
||||
background-color: #edf5ff;
|
||||
color: #1f68e9;
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
.content .button-content .button.type3.data-v-cb7a366a {
|
||||
border: 2rpx solid #c4c8d1;
|
||||
margin-top: 40rpx;
|
||||
}
|
||||
.content .notice.data-v-cb7a366a {
|
||||
color: rgba(94, 94, 107, 0.855);
|
||||
font-size: 24rpx;
|
||||
margin-top: 50rpx;
|
||||
text-align: center;
|
||||
}
|
||||
Reference in New Issue
Block a user