|
|
@@ -57,6 +57,7 @@ class ProductController extends BaseController
|
|
|
|
|
|
$itemInfoData = ProductClass::getAllByCondition($where, ['actualSold' => SORT_DESC, 'inTurn' => SORT_DESC], "*");
|
|
|
$itemInfoData = ProductClass::groupProductInfo($itemInfoData);
|
|
|
+
|
|
|
//常用的itemIds
|
|
|
$oftenItemIds = ProductClass::getOftenItemIds($shopId);
|
|
|
//获取供应商下所有花材ID (itemIds)
|
|
|
@@ -66,7 +67,7 @@ class ProductController extends BaseController
|
|
|
//组装数据: [{classId:'','className:'',child:[{itemInfoData}]}]
|
|
|
$data = ProductService::assembleData($classIds, $itemIdsInfo, $itemInfoData, $oftenItemIds, $type);
|
|
|
|
|
|
- util::success($data);
|
|
|
+ util::success(['list' => $data, 'product' => $itemInfoData]);
|
|
|
}
|
|
|
|
|
|
|