Files
yii2/tests/data/console/migrate_create/create_id_pk.php
Nikola Kovacs 84124bec4f Fix grammar in migration template docblocks. (#12148)
Fix typo in test file's name.
2016-08-12 17:55:43 +03:00

36 lines
547 B
PHP

<?php
return <<<CODE
<?php
use yii\db\Migration;
/**
* Handles the creation of table `test`.
*/
class {$class} extends Migration
{
/**
* @inheritdoc
*/
public function up()
{
\$this->createTable('test', [
'id' => \$this->primaryKey(),
'address' => \$this->string(),
'address2' => \$this->string(),
'email' => \$this->string(),
]);
}
/**
* @inheritdoc
*/
public function down()
{
\$this->dropTable('test');
}
}
CODE;