From 36cae90d74c838d299279d8e1193d015644214fe Mon Sep 17 00:00:00 2001
From: YuanHuakk <1751826683@qq.com>
Date: Wed, 29 Nov 2023 23:07:30 +0800
Subject: [PATCH] =?UTF-8?q?fix(custom):=20=E4=BF=AE=E5=A4=8D=E7=A7=AF?=
=?UTF-8?q?=E5=88=86=E6=94=AF=E4=BB=98=E6=88=90=E5=8A=9F=E4=B8=8D=E8=B7=B3?=
=?UTF-8?q?=E8=BD=AC?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
src/components/Pay.vue | 22 +++++++++++-----------
src/pages/users/order_list/index.vue | 8 ++++++--
2 files changed, 17 insertions(+), 13 deletions(-)
diff --git a/src/components/Pay.vue b/src/components/Pay.vue
index 390ccd7..213049d 100644
--- a/src/components/Pay.vue
+++ b/src/components/Pay.vue
@@ -111,9 +111,9 @@ const goPay = async (type: number) => {
OrderType: prop.OrderType,
PayType: type,
});
- if (data.data) {
- // 1微信支付 2积分支付
- if (type === 1) {
+ // 1微信支付 2积分支付
+ if (type === 1) {
+ if (data.data) {
Taro.requestPayment({
timeStamp: data.data.timeStamp,
nonceStr: data.data.nonceStr,
@@ -139,25 +139,25 @@ const goPay = async (type: number) => {
});
} else {
Taro.showToast({
- title: "支付成功",
- icon: "success",
- duration: 2000,
+ title: "未知异常",
+ icon: "none",
});
- emit("successPay", false);
+ emit("closePay", false);
}
} else {
Taro.showToast({
- title: "未知异常",
- icon: "none",
+ title: "支付成功",
+ icon: "success",
+ duration: 2000,
});
- emit("closePay", false);
+ emit("successPay", false);
}
} catch (e) {
Taro.showToast({
title: e.msg,
icon: "none",
});
- // emit("closePay", false);
+ emit("closePay", false);
throw e;
}
};
diff --git a/src/pages/users/order_list/index.vue b/src/pages/users/order_list/index.vue
index f1c22bd..5953be5 100644
--- a/src/pages/users/order_list/index.vue
+++ b/src/pages/users/order_list/index.vue
@@ -147,7 +147,8 @@ const countInfo = ref<{
C?: number;
D?: number;
F?: number;
- Total?: number;
+ ExchangeTotal?: number;
+ PriceTotal?: number;
}>({});
const getTj = async () => {
@@ -176,7 +177,10 @@ const getTj = async () => {
订单信息
总消费积分:{{ countInfo.Total || 0 }}
+ >总消费积分:{{ countInfo.ExchangeTotal || 0 }}
+
+ 总消费金额:{{ countInfo.PriceTotal || 0 }}