Browse Source

静态页面

xcx 4 years ago
parent
commit
a20af6e9b9
2 changed files with 3 additions and 5 deletions
  1. 2
    4
      src/pages/WuYe/JiaoFeiDetail/index.jsx
  2. 1
    1
      src/utils/api.js

+ 2
- 4
src/pages/WuYe/JiaoFeiDetail/index.jsx View File

@@ -58,20 +58,18 @@ export default function JiaoFeiDetail () {
58 58
       order.current = res
59 59
       const outTradeNo = res.outTradeNo
60 60
       // 下单
61
-      request({ ...apis.wxUnifiedOrder, args: { outTradeNo }, params: { type: 'bill' } }).then(res => {
61
+      request({ ...apis.wxUnifiedOrder, args: { outTradeNo }, params: { type: 'bill' } }).then(() => {
62 62
         Taro.requestPayment({
63 63
           timeStamp: `${res.timeStamp}`,
64 64
           nonceStr: res.nonceStr,
65 65
           package: res.package,
66 66
           paySign: res.sign,
67 67
           signType: res.signType,
68
-          success: resp => {
69
-            console.log('支付结果:', resp)
68
+          success: () => {
70 69
             paying.current = false
71 70
             order.current = undefined
72 71
             setShowPopup(false)
73 72
             setPopupType(0)
74
-
75 73
             Taro.showToast({
76 74
               title: '支付成功',
77 75
               icon: 'success'

+ 1
- 1
src/utils/api.js View File

@@ -110,7 +110,7 @@ const $api = {
110 110
 
111 111
   wxStartPay: {
112 112
     method: 'post',
113
-    url: `${prefix}/wxStartPay `
113
+    url: `${prefix}/wxStartPay`
114 114
   },
115 115
 
116 116
   wxCancelPay: {