瀏覽代碼

Merge branch 'dev' of http://git.ycjcjy.com/shigongli/miniapp-v2 into dev

吃个甘蔗嚼一年 3 年之前
父節點
當前提交
ae47c047c6
共有 2 個檔案被更改,包括 32 行新增11 行删除
  1. 32
    10
      src/components/CompoentsOrder/OrderCard/index.jsx
  2. 0
    1
      src/pages/index/tabs/Recommend.jsx

+ 32
- 10
src/components/CompoentsOrder/OrderCard/index.jsx 查看文件

@@ -60,17 +60,39 @@ export default (props) => {
60 60
       url: `/pages/MineUserAll/RefundMoney/CheckRefund/index?id=${item.orderId}`,
61 61
     });
62 62
   };
63
-  const PayAction =
64
-    kkp == '1' ? null ://空卡片用于售后详情页面
65
-      sh == '1' ? <Action.Icon icon={Refund} text='售后/退款' onClick={() => handleRefund(item)} /> ://售后页面卡片
66
-        item.status === 0 ? <Action.Icon icon={Pay} text='支付' onClick={handleDetail} /> ://待支付
67
-          item.status === 1 && item.isVerified == false ? <Action.Icon icon={QRcode} text='扫码核销' onClick={() => onWriteOff(item)} /> ://待核销
68
-            item.status === 2 && item.isVerified == false ? <Action.Image image={refund} /> ://已退费
69
-              item.status === 7 && item.isVerified == false ? <Action.Image image={Cancel} /> ://已取消
70
-                item.status === 9 ? <Action.Image image={Null} /> ://已过期
71
-                  item.isVerified == true && item.isEvaluated > 0 ? <Action.Image image={Evaluated} /> ://已评价
72
-                    item.isVerified == true ? <Action.Icon icon={Evaluation} text='评价' onClick={() => evaluation(item)} /> : null//待评价
63
+  // const PayAction =
64
+  //   kkp == '1' ? null ://空卡片用于售后详情页面
65
+  //     sh == '1' ? <Action.Icon icon={Refund} text='售后/退款' onClick={() => handleRefund(item)} /> ://售后页面卡片
66
+  //       item.status === 0 ? <Action.Icon icon={Pay} text='支付' onClick={handleDetail} /> ://待支付
67
+  //         item.status === 1 && item.isVerified == false ? <Action.Icon icon={QRcode} text='扫码核销' onClick={() => onWriteOff(item)} /> ://待核销
68
+  //           item.status === 2 && item.isVerified == false ? <Action.Image image={refund} /> ://已退费
69
+  //             item.status === 7 && item.isVerified == false ? <Action.Image image={Cancel} /> ://已取消
70
+  //               item.status === 9 ? <Action.Image image={Null} /> ://已过期
71
+  //                 item.isVerified == true && item.isEvaluated > 0 ? <Action.Image image={Evaluated} /> ://已评价
72
+  //                   item.isVerified == true ? <Action.Icon icon={Evaluation} text='评价' onClick={() => evaluation(item)} /> : null//待评价
73 73
 
74
+  let PayAction=null
75
+  if (kkp=='1') {//空卡片用于售后详情页面
76
+    PayAction=null
77
+  }else if (sh=='1') {//售后页面卡片
78
+     PayAction=<Action.Icon icon={Refund} text='售后/退款' onClick={() => handleRefund(item)} />
79
+  }else if (item.status===0) {//待支付
80
+     PayAction=<Action.Icon icon={Pay} text='支付' onClick={handleDetail} />
81
+  }else if (item.status === 1 && item.isVerified == false) {//待核销
82
+     PayAction=<Action.Icon icon={QRcode} text='扫码核销' onClick={() => onWriteOff(item)} />
83
+  }else if (item.status === 2 && item.isVerified == false) {//已退费
84
+     PayAction=<Action.Image image={refund} />
85
+  }else if (item.status === 7 && item.isVerified == false) {//已取消
86
+     PayAction=<Action.Image image={Cancel} />
87
+  }else if(item.status === 9){//已过期
88
+     PayAction=<Action.Image image={Null} />
89
+  }else if (item.isVerified == true && item.isEvaluated > 0) {//已评价
90
+     PayAction=<Action.Image image={Evaluated} />
91
+  }else if (item.isVerified == true) {//待评价
92
+     PayAction=<Action.Icon icon={Evaluation} text='评价' onClick={() => evaluation(item)} />
93
+  }else{
94
+    PayAction=null
95
+  }
74 96
 
75 97
   return (
76 98
     <>

+ 0
- 1
src/pages/index/tabs/Recommend.jsx 查看文件

@@ -1,6 +1,5 @@
1 1
 import Taro, { useDidShow } from '@tarojs/taro'
2 2
 import { React, useState, useEffect, useRef } from 'react'
3
-import { View } from '@tarojs/components';
4 3
 import iconsearch from '@/assets/icons/housemantj/search.png'
5 4
 import locationimg from '@/assets/icons/housemantj/location.png'
6 5
 import Tip from '@/components/tip'