]> gitweb.erp-flowers.ru Git - erp24_rep/yii-erp24/.git/commitdiff
Правки методов feature_fomichev_erp-419_calculate_cleared_species_month_goal
authorfomichev <vladimir.fomichev@erp-flowers.ru>
Wed, 4 Jun 2025 09:40:32 +0000 (12:40 +0300)
committerfomichev <vladimir.fomichev@erp-flowers.ru>
Wed, 4 Jun 2025 09:40:32 +0000 (12:40 +0300)
erp24/controllers/CategoryPlanController.php
erp24/services/StorePlanService.php

index 0947df5f53f5348005a55c6f8eaffd835057a0fb..5a1f751e6005595c2a6a91bbcdc0b9ad8f8a2bf9 100644 (file)
@@ -355,7 +355,7 @@ class CategoryPlanController extends Controller {
                         $result['without_history']
                     );
 
-                    $productSalesShare = StorePlanService::calculateProductSalesShare(
+                    $productSalesShare = StorePlanService::calculateProductSalesShareProductsWithHistory(
                         $storeId,
                         $selectedMonth,
                         $result['with_history']
index 20d954b58f3fda719bd142b025d7f4c842758223..5b6141b37250c3827388c7675c95384a895a0269 100755 (executable)
@@ -626,7 +626,7 @@ class StorePlanService
                 ->andWhere([
                     'or',
                     ['>=', 'date_to',   $weekStart->format('Y-m-d')],
-                    ['date_to' => '2100-01-01 03:00:00+03']
+                    ['date_to' => '2100-01-01 00:00:00+03']
                 ])
                 ->all();
 
@@ -981,7 +981,7 @@ class StorePlanService
      *              'monthlyPrice'    => [ 'YYYY-MM' => цена ]
      *          ]
      */
-    public static function calculateProductSalesShare($storeId, $selectedMonth, $productsWithHistory)
+    public static function calculateProductSalesShareProductsWithHistory($storeId, $selectedMonth, $productsWithHistory)
     {
         $targetDate = strtotime(date('Y') . "-$selectedMonth-01");