diff --git a/app/common/repositories/store/order/StoreOrderRepository.php b/app/common/repositories/store/order/StoreOrderRepository.php index a1f38313..381d60c3 100644 --- a/app/common/repositories/store/order/StoreOrderRepository.php +++ b/app/common/repositories/store/order/StoreOrderRepository.php @@ -1817,17 +1817,17 @@ class StoreOrderRepository extends BaseRepository $order->takeOrderCount = count($order['takeOrderList']); unset($order['takeOrderList']); } - $orders = $list->toArray(); - $merIds = array_unique(array_column($orders, 'mer_id')); + $list = $list->toArray(); + $merIds = array_unique(array_column($list, 'mer_id')); /** @var ProductLabelRepository $labelRepo */ $labelRepo = app()->make(ProductLabelRepository::class); - foreach ($orders as &$order) { + foreach ($list as &$order) { $labelRepo->isOrder = true; $labelRepo->merTypeId = $order['merchant']['type_id']; $labelRepo->isWholeSale = $order['sale_type'] == Enum::SALE_TYPE_WHOLESALE; $order['orderProduct'] = $labelRepo->appendLabel($merIds, $order['orderProduct']); } - return compact( 'count','orders'); + return compact( 'count','list'); } public function userList($uid, $page, $limit)