From e5e06e6842e0291a443bde98f876ff8abaf048d5 Mon Sep 17 00:00:00 2001 From: marina Date: Tue, 15 Oct 2024 10:49:47 +0300 Subject: [PATCH] =?utf8?q?ERP-224=20=D0=94=D0=BE=D1=80=D0=B0=D0=B1=D0=BE?= =?utf8?q?=D1=82=D0=B0=D1=82=D1=8C=20=D0=A4=D0=B0=D0=BA=D1=82=20=D0=B2=20?= =?utf8?q?=D1=82=D0=B0=D0=B1=D0=BB=D0=B8=D1=86=D0=B5=20=D0=BC=D0=BE=D1=82?= =?utf8?q?=D0=B8=D0=B2=D0=B0=D1=86=D0=B8=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- erp24/services/MotivationService.php | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/erp24/services/MotivationService.php b/erp24/services/MotivationService.php index 3ab5b416..0f98f9fe 100644 --- a/erp24/services/MotivationService.php +++ b/erp24/services/MotivationService.php @@ -217,6 +217,7 @@ class MotivationService 'forecast' => null, 'fact' => null, 'deviation' => null, + 'is_combined' => $costsItem->is_combined ]; } @@ -234,8 +235,12 @@ class MotivationService } $result[$costsItem->order][$groupAlias] = $actualValue; - } + if ($result[$costsItem->order]['is_combined'] == true + && (empty($result[$costsItem->order]['fact']) || $result[$costsItem->order]['fact'] == 0)) { + $result[$costsItem->order]['fact'] = $result[$costsItem->order]['plan']; + } + } // Подстановка значений расходных материалов //190 - порядок для расходных материалов -- 2.39.5