소스 검색

为机器人波次处理商品时增加一次库位校长

LD 5 년 전
부모
커밋
fb75e70715
1개의 변경된 파일4개의 추가작업 그리고 5개의 파일을 삭제
  1. 4 5
      app/Services/OrderCommodityService.php

+ 4 - 5
app/Services/OrderCommodityService.php

@@ -37,14 +37,13 @@ class OrderCommodityService
             ->where('orderno',data_get($orderCommodities,'*.order.code')??[])
             ->where('waveno',data_get($orderCommodities,'*.order.batch.code')??[])
             ->get(['orderno','location','waveno']);
-        foreach($orderCommodities as $orderCommodity){
-            $a=$details
+        foreach($orderCommodities as &$orderCommodity){
+            $orderCommodity['location'] ==$details
                 ->where('orderno',$orderCommodity['order']['code'])
                 ->where('waveno',$orderCommodity['order']['batch']['code'])
-                ->first();
-            dump($a);
+                ->first()['location']??'';
         }
-//        dd($details);
+        return $orderCommodities;
     }
     public function batchUpdate($updateParams){
         return app(BatchUpdateService::class)->batchUpdate('order_commodities',$updateParams);