| Total Complexity | 2 |
| Total Lines | 25 |
| Duplicated Lines | 0 % |
| Changes | 1 | ||
| Bugs | 0 | Features | 0 |
| 1 | <?php |
||
| 8 | class m180126_183432_create_user_table extends Migration |
||
| 9 | { |
||
| 10 | /** |
||
| 11 | * {@inheritdoc} |
||
| 12 | */ |
||
| 13 | public function safeUp() |
||
| 14 | { |
||
| 15 | $this->createTable('user', [ |
||
| 16 | 'id' => $this->primaryKey(), |
||
| 17 | 'username' => $this->string()->notNull(), |
||
| 18 | 'email' => $this->string()->notNull(), |
||
| 19 | 'image' => $this->string(), |
||
| 20 | 'google_user_id' => $this->string()->notNull(), |
||
| 21 | 'active' => $this->boolean()->notNull()->defaultValue(0), |
||
| 22 | 'updated_at' => $this->dateTime(), |
||
| 23 | 'created_at' => $this->dateTime(), |
||
| 24 | ]); |
||
| 25 | } |
||
| 26 | |||
| 27 | /** |
||
| 28 | * {@inheritdoc} |
||
| 29 | */ |
||
| 30 | public function safeDown() |
||
| 33 | } |
||
| 34 | } |
||
| 35 |