From f959c272c2d75b7d0641bd76d95d1d98ee5b329d Mon Sep 17 00:00:00 2001 From: marina Date: Tue, 17 Jun 2025 14:01:56 +0300 Subject: [PATCH] =?utf8?q?ERP-360=20=D0=A1=D0=B1=D0=BE=D1=80=D0=BA=D0=B0?= =?utf8?q?=20=D1=81=D1=82=D1=80=D0=B0=D0=BD=D0=B8=D1=86=D1=8B=20=D0=B0?= =?utf8?q?=D0=B2=D1=82=D0=BE=D0=BF=D0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- erp24/api2/controllers/OrdersController.php | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/erp24/api2/controllers/OrdersController.php b/erp24/api2/controllers/OrdersController.php index 1f6f09dc..8ab6caec 100644 --- a/erp24/api2/controllers/OrdersController.php +++ b/erp24/api2/controllers/OrdersController.php @@ -199,9 +199,9 @@ class OrdersController extends BaseController } $storesGuidId = array_flip(array_filter(CityStore::getAllActiveGuidId(), fn($v) => is_int($v) || is_string($v))); - $storeGuid = $data['store-guid'] ?? null; + $storeGuid = $data['store_id'] ?? null; if (empty($storeGuid)) { - throw new \Exception('store-guid не передан или пуст'); + throw new \Exception('store_id не передан или пуст'); } $storeId = $storesGuidId[$storeGuid]; @@ -219,15 +219,12 @@ class OrdersController extends BaseController $result = []; foreach ($orders as $order) { $products = []; - $productsWithoutGuid = []; foreach ($order->items as $product) { $product1c = Products1c::findOne(['articule' => $product->offer_id]); if ($product1c) { $products[$product1c->id] = $product->count; - } else { - $productsWithoutGuid[$product->offer_name] = $product->count; } } @@ -235,7 +232,6 @@ class OrdersController extends BaseController 'order_id' => $order->guid, 'status' => $order->status_id, 'products' => $products, - 'products_without_guid' => $productsWithoutGuid, ]; } -- 2.39.5