From 24e5bff3f183f9b857e530fd79f92d28907520be Mon Sep 17 00:00:00 2001 From: marina Date: Fri, 20 Dec 2024 09:23:20 +0300 Subject: [PATCH] =?utf8?q?ERP-256=20=D0=A1=D0=B4=D0=B5=D0=BB=D0=B0=D1=82?= =?utf8?q?=D1=8C=20=D0=BE=D1=82=D0=BF=D1=80=D0=B0=D0=B2=D0=BA=D1=83=20?= =?utf8?q?=D0=B4=D0=BE=D0=BA=D1=83=D0=BC=D0=B5=D0=BD=D1=82=D0=BE=D0=B2=20?= =?utf8?q?=D0=9F=D0=B5=D1=80=D0=B5=D1=81=D0=BE=D1=80=D1=82=D0=B8=D1=86?= =?utf8?q?=D0=B0=20=D0=B2=201=D1=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- erp24/actions/timetable/StartShiftStepTwoAction.php | 5 +++-- erp24/records/TimetableFactModel.php | 10 +++++----- 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/erp24/actions/timetable/StartShiftStepTwoAction.php b/erp24/actions/timetable/StartShiftStepTwoAction.php index d0000501..693d5ad2 100755 --- a/erp24/actions/timetable/StartShiftStepTwoAction.php +++ b/erp24/actions/timetable/StartShiftStepTwoAction.php @@ -165,9 +165,10 @@ class StartShiftStepTwoAction extends Action 'device' => $device, 'planSlots' => $planSlots, ]); - } else { - var_dump($model->errors);die(); } +// else { +// var_dump($model->errors);die(); +// } } return $this->controller->render('/timetable/start_shift_step_two.php', [ diff --git a/erp24/records/TimetableFactModel.php b/erp24/records/TimetableFactModel.php index ed2f2140..e7304d30 100644 --- a/erp24/records/TimetableFactModel.php +++ b/erp24/records/TimetableFactModel.php @@ -92,11 +92,11 @@ class TimetableFactModel extends ActiveRecord [['checkin_start_id', 'checkin_end_id'], 'exist', 'targetClass' => AdminCheckin::class, 'targetAttribute' => 'id', 'skipOnEmpty' => true], [['admin_id', 'admin_id_add'], 'exist', 'targetClass' => Admin::class, 'targetAttribute' => 'id', 'skipOnEmpty' => true], [['store_id'], 'exist', 'targetClass' => CityStore::class, 'targetAttribute' => 'id', 'skipOnEmpty' => true], - ['time_end', function($attribute) { - if (strtotime($this->$attribute) - strtotime($this->time_start) < 120) { - $this->addError($attribute, 'Интервал между сменами должен быть не менее 2 минут.'); - } - }], +// ['time_end', function($attribute) { +// if (strtotime($this->$attribute) - strtotime($this->time_start) < 120) { +// $this->addError($attribute, 'Интервал между сменами должен быть не менее 2 минут.'); +// } +// }], // [['work_time'], 'number', 'min' => 0, 'max' => 24], [['comment'], 'string'], [['comment'], 'default', 'value' => null], -- 2.39.5