shish 2 years ago
parent
commit
9a11e52db1
1 changed files with 2 additions and 1 deletions
  1. 2 1
      app-ghs/controllers/ItemController.php

+ 2 - 1
app-ghs/controllers/ItemController.php

@@ -70,7 +70,8 @@ class ItemController extends BaseController
         } elseif ($requestType == 'kd') {
             //开单的花材列表
             $field = 'id,py,cover,name,cost,itemId,classId,skPrice,variety,price,hjPrice,hjDiscountPrice,skDiscountPrice,discountPrice,stock,weight,stockWarning,presell,ratioType,smallUnit,smallRatio,bigUnit,ratio,frontHide,reachNum,reachNumDiscount';
-            $itemInfoData = ProductClass::getList($field, $where, ['inTurn' => SORT_DESC, 'actualSold' => SORT_DESC]);
+            $result = ProductClass::getList($field, $where, ['inTurn' => SORT_DESC, 'actualSold' => SORT_DESC]);
+            $itemInfoData = $result['list'] ?? [];
             $itemInfoData = ProductClass::kdItemGroup($itemInfoData, $level);
         } elseif ($requestType == 'book') {
             //预订花材列表