From: marina Date: Tue, 10 Jun 2025 10:20:58 +0000 (+0300) Subject: ERP-360 Сборка страницы автопм X-Git-Url: https://gitweb.erp-flowers.ru/?a=commitdiff_plain;h=93cdb11a19406c79d717811e886ac140a4e725b6;p=erp24_rep%2Fyii-erp24%2F.git ERP-360 Сборка страницы автопм --- diff --git a/erp24/views/auto-plannogramma/index.php b/erp24/views/auto-plannogramma/index.php index 5e992d71..64c26337 100644 --- a/erp24/views/auto-plannogramma/index.php +++ b/erp24/views/auto-plannogramma/index.php @@ -34,8 +34,14 @@ $this->registerJsFile('/js/autoplannogramma/autoplannogramma.js', ['position' => 'year-filter', 'data' => array_combine(range(date('Y') - 5, date('Y') + 5), range(date('Y') - 5, date('Y') + 5)), - 'options' => ['placeholder' => 'Год', 'id' => 'year'], - 'pluginOptions' => ['allowClear' => true], + 'value' => (string)date('Y'), + 'options' => [ + 'placeholder' => 'Год', + 'id' => 'year', + ], + 'pluginOptions' => [ + 'allowClear' => true, + ], ]) ?>
@@ -86,8 +92,14 @@ $this->registerJsFile('/js/autoplannogramma/autoplannogramma.js', ['position' => 'week-filter', 'data' => array_combine(range(1, 53), range(1, 53)), - 'options' => ['placeholder' => 'Неделя', 'id' => 'week'], - 'pluginOptions' => ['allowClear' => true], + 'value' => (date('W') + 8) > 53 ? (date('W') + 8 - 53) : (date('W') + 8), + 'options' => [ + 'placeholder' => 'Неделя', + 'id' => 'week', + ], + 'pluginOptions' => [ + 'allowClear' => true, + ], ]) ?>