From: Vladimir Fomichev Date: Wed, 20 Aug 2025 14:04:51 +0000 (+0300) Subject: Merge branch 'refs/heads/develop' into feature_fomichev_erp-457_nomenclature_actualit... X-Git-Url: https://gitweb.erp-flowers.ru/?a=commitdiff_plain;h=2c63ddbc37476f9dae698950fc55d093b3c3e099;p=erp24_rep%2Fyii-erp24%2F.git Merge branch 'refs/heads/develop' into feature_fomichev_erp-457_nomenclature_actuality_autoplan_calculate # Conflicts: # erp24/services/AutoPlannogrammaService.php --- 2c63ddbc37476f9dae698950fc55d093b3c3e099 diff --cc erp24/services/AutoPlannogrammaService.php index e5a6c946,cd178acd..1b59010a --- a/erp24/services/AutoPlannogrammaService.php +++ b/erp24/services/AutoPlannogrammaService.php @@@ -3133,13 -3236,13 +3247,17 @@@ private function buildCategoryGoals(arr $salesShares[$storeId]['marketplace'] = round($market / $total, 4); } } + foreach ($weeklyForecasts as $item) { + $groupsArr = explode('_', (string)$item['matrix_group']); + $baseGroup = $groupsArr[0]; $storeItem = (int)$item['store_id']; $guid = (string)$item['product_guid']; + $group = $baseGroup; + if (!in_array($guid, $actualProducts)) { + continue; + } + $group = (string)$item['matrix_group']; $type = (string)$item['type']; $forecastValue = (float)$item['week_forecast']; if (isset($salesShares[$storeItem]) && isset($salesShares[$storeItem][$type])) {