|
1234567891011121314151617181920212223242526272829303132 |
- <?php
-
- use yii\db\Migration;
- use yii\db\Schema;
-
- /**
- * Class m231006_084312_add_columns_subscription_created_updated
- */
- class m231006_084312_add_columns_subscription_created_updated extends Migration
- {
- /**
- * {@inheritdoc}
- */
- public function safeUp()
- {
- $this->addColumn('subscription', 'id_created_by', Schema::TYPE_INTEGER);
- $this->addColumn('subscription', 'created_at', Schema::TYPE_DATETIME);
- $this->addColumn('subscription', 'id_updated_by', Schema::TYPE_INTEGER);
- $this->addColumn('subscription', 'updated_at', Schema::TYPE_DATETIME);
- }
-
- /**
- * {@inheritdoc}
- */
- public function safeDown()
- {
- $this->dropColumn('subscription', 'id_created_by');
- $this->dropColumn('subscription', 'created_at');
- $this->dropColumn('subscription', 'id_updated_by');
- $this->dropColumn('subscription', 'updated_at');
- }
- }
|