From eb418a91e994368a26d29f648edd6a45c84d828b Mon Sep 17 00:00:00 2001 From: vladfo Date: Fri, 18 Oct 2024 20:01:25 +0300 Subject: [PATCH] =?utf8?q?=D0=98=D0=B7=D0=BC=D0=B5=D0=BD=D0=B5=D0=BD=D0=B8?= =?utf8?q?=D0=B5=20=D0=BC=D0=B8=D0=B3=D1=80=D0=B0=D1=86=D0=B8=D0=B8=20?= =?utf8?q?=D0=B8=20=D1=83=D0=B4=D0=B0=D0=BB=D0=B5=D0=BD=D0=B8=D0=B5=20?= =?utf8?q?=D0=BD=D0=BE=D0=B2=D0=BE=D0=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit --- ...1015_125203_create_cluster_admin_table.php | 1 + ..._table_cluster_admin_add_column_active.php | 42 ------------------- 2 files changed, 1 insertion(+), 42 deletions(-) delete mode 100644 erp24/migrations/m241018_114640_alter_table_cluster_admin_add_column_active.php diff --git a/erp24/migrations/m241015_125203_create_cluster_admin_table.php b/erp24/migrations/m241015_125203_create_cluster_admin_table.php index ee4e5722..36374ebd 100644 --- a/erp24/migrations/m241015_125203_create_cluster_admin_table.php +++ b/erp24/migrations/m241015_125203_create_cluster_admin_table.php @@ -19,6 +19,7 @@ class m241015_125203_create_cluster_admin_table extends Migration 'admin_id' => $this->integer()->notNull()->comment('ID пользователя'), 'date_start' => $this->date()->notNull()->comment('Дата начала привязки'), 'date_end' => $this->date()->defaultValue('2100-01-01')->notNull()->comment('Дата окончания привязки'), + 'active' => $this->tinyInteger()->notNull()->defaultValue(0)->comment('0 - запись не активная 1 - запись привязки активная'), ]); } diff --git a/erp24/migrations/m241018_114640_alter_table_cluster_admin_add_column_active.php b/erp24/migrations/m241018_114640_alter_table_cluster_admin_add_column_active.php deleted file mode 100644 index c3e1a27e..00000000 --- a/erp24/migrations/m241018_114640_alter_table_cluster_admin_add_column_active.php +++ /dev/null @@ -1,42 +0,0 @@ -addColumn(self::TABLE_NAME, 'active', $this->tinyInteger()->notNull()->defaultValue(0) - ->after('date_end')->comment('0 - запись не активная 1 - запись привязки активная')); - } - - /** - * {@inheritdoc} - */ - public function safeDown() - { - $this->dropColumn(self::TABLE_NAME, 'active'); - } - - /* - // Use up()/down() to run migration code without a transaction. - public function up() - { - - } - - public function down() - { - echo "m241018_114640_alter_table_cluster_admin_add_column_active cannot be reverted.\n"; - - return false; - } - */ -} -- 2.39.5