Commit 5ebc25de authored by Shakarim Sapa's avatar Shakarim Sapa

- Добавлена миграция. Таблица курсов

parent d6ef4c86
<?php
use yii\db\Migration;
class m160410_081133_add_new_course_table extends Migration
{
// Use safeUp/safeDown to run migration code within a transaction
public function safeUp()
{
$this->createTable(
'analytics_school_course',
[
'id' => $this->primaryKey(),
'name' => $this->string(255)->notNull(),
'description' => $this->text()->defaultValue(null),
'image' => $this->text()->defaultValue(null)
]
);
}
public function safeDown()
{
$this->dropTable('analytics_school_course');
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment