shish 2 년 전
부모
커밋
a48575e5a3
1개의 변경된 파일6개의 추가작업 그리고 4개의 파일을 삭제
  1. 6 4
      app-ghs/controllers/ItemController.php

+ 6 - 4
app-ghs/controllers/ItemController.php

@@ -178,18 +178,20 @@ class ItemController extends BaseController
                         $needCgList[$biProductId] = $biInfo->needCgNum;
                         $needCgList[$biProductId] = $biInfo->needCgNum;
                     }
                     }
                 }
                 }
-                print_r($myIds);die;
                 if ($globalCgMyCharge == 1) {
                 if ($globalCgMyCharge == 1) {
-                    if(!empty($myIds)){
+                    if (!empty($myIds)) {
                         $where['id'] = ['in', $myIds];
                         $where['id'] = ['in', $myIds];
-                    }else{
+                    } else {
                         $where['id'] = ['in', [0]];
                         $where['id'] = ['in', [0]];
                     }
                     }
                 }
                 }
+            } else {
+                if ($globalCgMyCharge == 1) {
+                    $where['id'] = ['in', [0]];
+                }
             }
             }
         }
         }
 
 
-
         $result = ProductClass::getList($field, $where, ['inTurn' => SORT_DESC, 'actualSold' => SORT_DESC]);
         $result = ProductClass::getList($field, $where, ['inTurn' => SORT_DESC, 'actualSold' => SORT_DESC]);
         $list = $result['list'] ?? [];
         $list = $result['list'] ?? [];
         if ($requestType == 'hasStockList') {
         if ($requestType == 'hasStockList') {