From: vladfo Date: Fri, 19 Jul 2024 13:19:48 +0000 (+0300) Subject: change created_at in migration X-Git-Tag: 1.4~18^2^2~4 X-Git-Url: https://gitweb.erp-flowers.ru/?a=commitdiff_plain;h=8abd649216f80a691e73a60b8ddf1a1e4e14656d;p=erp24_rep%2Fyii-erp24%2F.git change created_at in migration --- diff --git a/erp24/migrations/m240719_090134_create_motivation_values_table.php b/erp24/migrations/m240719_090134_create_motivation_values_table.php index f87eb3ed..bf9022ef 100644 --- a/erp24/migrations/m240719_090134_create_motivation_values_table.php +++ b/erp24/migrations/m240719_090134_create_motivation_values_table.php @@ -23,8 +23,8 @@ class m240719_090134_create_motivation_values_table extends Migration 'name' => $this->string()->notNull(), 'data_type' => "data_type_enum NOT NULL", 'is_active' => $this->boolean()->defaultValue(true), - 'created_at' => $this->timestamp()->defaultExpression('CURRENT_TIMESTAMP'), - 'updated_at' => $this->timestamp()->defaultExpression('CURRENT_TIMESTAMP'), + 'created_at' => $this->datetime()->notNull()->comment('дата создания записи'), + 'updated_at' => $this->datetime()->notNull()->comment('дата изменения записи'), ]); $this->createIndex('idx-motivation_values-name', '{{%motivation_values}}', 'name', true);