From e2b6f6e237a01dd3d673b96bf7abb556a079b89b Mon Sep 17 00:00:00 2001
From: XiaoXinPro 14 IAH5R <568170040@qq.com>
Date: Wed, 31 May 2023 12:46:57 +0800
Subject: [PATCH] upload
---
config/config.js | 4 ++
pages/coupon/confirmation/confirmation.js | 25 ++++++-
pages/coupon/confirmation/confirmation.ttml | 5 +-
pages/coupon/detail/index.js | 21 +++++-
pages/coupon/detail/index.ttml | 4 +-
pages/order/detail/index.js | 24 ++++++-
pages/order/detail/index.ttml | 5 +-
utils/imgurl.js | 74 +++++++++++----------
8 files changed, 118 insertions(+), 44 deletions(-)
diff --git a/config/config.js b/config/config.js
index 7b7c664..2667193 100644
--- a/config/config.js
+++ b/config/config.js
@@ -160,6 +160,10 @@ var config = {
* 订单退款状态
*/
getRefundStatus: "/order/getRefundStatus",
+ /**
+ * 获取im客服id
+ */
+ getIm: "/mallIm/getIm",
// 券包详情
// orderDetailAll: "/order/detail_v1",
/**
diff --git a/pages/coupon/confirmation/confirmation.js b/pages/coupon/confirmation/confirmation.js
index 9455904..4752728 100644
--- a/pages/coupon/confirmation/confirmation.js
+++ b/pages/coupon/confirmation/confirmation.js
@@ -14,7 +14,7 @@ Page({
spuIdObj: {},
priceAndStockObj: {},
mallTenantId: '',
- imId: "69168503086",
+ imId: "",
goodId: "",
IMorderId: ""
},
@@ -75,6 +75,25 @@ Page({
},
});
},
+
+ getIm() { //获取im客服id
+ const that = this
+ Http.get({
+ url: config.api.getIm,
+ data: {
+ mallTenantId: this.data.mallTenantId || ''
+ }
+ }).then(res => {
+ console.log(res, 'getIm');
+ const imId = res.data.imId || ''
+ that.setData({
+ imId: imId
+ })
+ }).catch(err => {
+ console.log(err, 'res');
+ })
+ },
+
getSupId(id) {
Http.get({
url: config.api.getSpuid,
@@ -952,4 +971,8 @@ Page({
}
})
},
+
+ onShow() {
+ this.getIm()
+ }
})
\ No newline at end of file
diff --git a/pages/coupon/confirmation/confirmation.ttml b/pages/coupon/confirmation/confirmation.ttml
index d5b8d39..22063c9 100644
--- a/pages/coupon/confirmation/confirmation.ttml
+++ b/pages/coupon/confirmation/confirmation.ttml
@@ -18,8 +18,9 @@
{{data.type==50?priceAndStockObj.creditPrice+'积分':priceAndStockObj.salePrice/100}}
{{data.type==50?'立即换购':'提交订单'}}
-