]> gitweb.erp-flowers.ru Git - erp24_rep/yii-erp24/.git/commitdiff
скрипт для объединения задублированных смен
authormarina <m.zozirova@gmail.com>
Mon, 8 Jul 2024 06:45:25 +0000 (09:45 +0300)
committermarina <m.zozirova@gmail.com>
Mon, 8 Jul 2024 06:45:25 +0000 (09:45 +0300)
erp24/controllers/TimetableFactController.php

index d1473406c0128b17f5dbeb49c48661e76ab73189..c05bc0cce5a88aa05a33cc100ec878e607688425 100644 (file)
@@ -358,7 +358,7 @@ class TimetableFactController extends Controller
         if ($action == 'applyPlus') {
             $plans = Timetable::find()
                 ->andWhere(['>=', 'date', '2024-07-01'])
-                ->andWhere(['<=', 'date', '2024-07-05'])
+                ->andWhere(['<=', 'date', date('Y-m-d')])
 //                ->andWhere(['=', 'id', 111309])
                 ->all();
 
@@ -405,7 +405,7 @@ class TimetableFactController extends Controller
         $dataProvider = new ActiveDataProvider([
             'query' => TimetableFactModel::find()
                 ->andWhere(['>=', 'date_shift', '2024-07-01'])
-                ->andWhere(['<=', 'date_shift', '2024-07-05'])
+                ->andWhere(['<=', 'date_shift', date('Y-m-d')])
                 ->orderBy('date_shift, admin_id,id,  store_id'),
             'pagination' => [
                 'pageSize' => false