| @@ 72-76 (lines=5) @@ | ||
| 69 | // 配送商品に含まれる商品種別を抽出. |
|
| 70 | $ShipmentItems = $Shipping->getProductOrderItems(); |
|
| 71 | $ProductTypes = array(); |
|
| 72 | foreach ($ShipmentItems as $ShipmentItem) { |
|
| 73 | $ProductClass = $ShipmentItem->getProductClass(); |
|
| 74 | $ProductType = $ProductClass->getProductType(); |
|
| 75 | $ProductTypes[$ProductType->getId()] = $ProductType; |
|
| 76 | } |
|
| 77 | ||
| 78 | // 商品種別に紐づく配送業者を取得. |
|
| 79 | $Deliveries = $this->deliveryRepository->getDeliveries($ProductTypes); |
|
| @@ 289-293 (lines=5) @@ | ||
| 286 | // 配送商品に含まれる商品種別を抽出. |
|
| 287 | $ShipmentItems = $Shipping->getShipmentItems(); |
|
| 288 | $ProductTypes = []; |
|
| 289 | foreach ($ShipmentItems as $ShipmentItem) { |
|
| 290 | $ProductClass = $ShipmentItem->getProductClass(); |
|
| 291 | $ProductType = $ProductClass->getProductType(); |
|
| 292 | $ProductTypes[$ProductType->getId()] = $ProductType; |
|
| 293 | } |
|
| 294 | ||
| 295 | // 商品種別に紐づく配送業者を取得. |
|
| 296 | $Deliveries = $this->deliveryRepository->getDeliveries($ProductTypes); |
|
| @@ 315-323 (lines=9) @@ | ||
| 312 | // 受注明細に含まれる商品種別を抽出. |
|
| 313 | $ProductTypes = []; |
|
| 314 | /** @var ShipmentItem $ShipmentItem */ |
|
| 315 | foreach ($ShipmentItems as $ShipmentItem) { |
|
| 316 | $ProductClass = $ShipmentItem->getProductClass(); |
|
| 317 | if (is_null($ProductClass)) { |
|
| 318 | // 商品明細のみ対象とする. 送料明細等はスキップする. |
|
| 319 | continue; |
|
| 320 | } |
|
| 321 | $ProductType = $ProductClass->getProductType(); |
|
| 322 | $ProductTypes[$ProductType->getId()] = $ProductType; |
|
| 323 | } |
|
| 324 | ||
| 325 | // 商品種別に紐づく配送業者を抽出 |
|
| 326 | $Deliveries = $this->deliveryRepository->getDeliveries($ProductTypes); |
|