Blame view

console/migrations/m160404_081649_banner.php 630 Bytes
4253cbec   root   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
  <?php

  

  use yii\db\Migration;

  

  class m160404_081649_banner extends Migration

  {

      public function up()

      {

          $this->createTable('{{%banner}}', [

              'banner_id' => $this->primaryKey(),

              'image' => $this->string(255),

              'alt' => $this->string(255),

              'title' => $this->string(255),

              'url' => $this->string(255),

              'status' => $this->smallInteger(1),

              'width' => $this->integer(4),

              'height' => $this->integer(4),

          ]);

      }

  

      public function down()

      {

          $this->dropTable('{{%banner}}');

      }

  

  }