35 lines
780 B
PHP
35 lines
780 B
PHP
<?php
|
|
|
|
use yii\db\Schema;
|
|
use yii\db\Migration;
|
|
|
|
class m151008_065256_alter__table__ticket__add_columns extends Migration
|
|
{
|
|
public function up()
|
|
{
|
|
$this->addColumn('ticket', 'id_card', 'int(11)');
|
|
$this->alterColumn('ticket', 'start', 'dateTime' );
|
|
$this->alterColumn('ticket', 'end', 'dateTime' );
|
|
$this->alterColumn('ticket', 'created_at', 'dateTime' );
|
|
$this->alterColumn('ticket', 'updated_at', 'dateTime' );
|
|
}
|
|
|
|
public function down()
|
|
{
|
|
// echo "m151008_065256_alter__table__ticket__add_columns cannot be reverted.\n";
|
|
|
|
// return false;
|
|
}
|
|
|
|
/*
|
|
// Use safeUp/safeDown to run migration code within a transaction
|
|
public function safeUp()
|
|
{
|
|
}
|
|
|
|
public function safeDown()
|
|
{
|
|
}
|
|
*/
|
|
}
|