dever há 6 anos atrás
pai
commit
73db69f21e
1 ficheiros alterados com 2 adições e 1 exclusões
  1. 2 1
      buy/src/Buy.php

+ 2 - 1
buy/src/Buy.php

@@ -29,7 +29,7 @@ class Buy extends Base
 
         if ($data) {
             foreach ($data as $k => $v) {
-                if ($v['cash'] > 0) {
+                if ($v['buy'] == 1 && $v['cash'] > 0) {
                     $data[$k]['price'] = '¥' . number_format($v['cash'], 2);
                 } else {
                     $data[$k]['price'] = '免费';
@@ -60,6 +60,7 @@ class Buy extends Base
     {
         $where['cate_id'] = $this->cate;
         $where['uid'] = $this->user['id'];
+        $where['status'] = 2;
         $where['type'] = 3;
         $data = Dever::db('act/order')->getMyAll($where);