Skip to content

Instantly share code, notes, and snippets.

@calcio
Last active March 24, 2017 13:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save calcio/d4f770173891ba635cf3897f4c3fe9f6 to your computer and use it in GitHub Desktop.
Save calcio/d4f770173891ba635cf3897f4c3fe9f6 to your computer and use it in GitHub Desktop.
<?php
use yii\db\Migration;
/**
* Handles the creation of table `about`.
*/
class m170203_135420_create_about_table extends Migration
{
/**
* @inheritdoc
*/
public function up()
{
$this->createTable('about', [
'id' => $this->primaryKey(),
'content' => $this->text()->notNull(),
'created_at' => $this->integer()->notNull(),
'updated_at' => $this->integer()->notNull(),
]);
}
/**
* @inheritdoc
*/
public function down()
{
$this->dropTable('about');
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment