Blame view

artweb/artbox-core/migrations/m170317_155205_addBlameableBehavior.php 847 Bytes
326af919   mzavalniuk   add artbox-core t...
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
27
28
29
30
31
32
  <?php
      
      use yii\db\Migration;
      
      class m170317_155205_addBlameableBehavior extends Migration
      {
          public function safeUp()
          {
              $this->addColumn(
                  'ImageManager',
                  'createdBy',
                  $this->integer(10)
                       ->unsigned()
                       ->null()
                       ->defaultValue(null)
              );
              $this->addColumn(
                  'ImageManager',
                  'modifiedBy',
                  $this->integer(10)
                       ->unsigned()
                       ->null()
                       ->defaultValue(null)
              );
          }
      
          public function safeDown()
          {
              $this->dropColumn('ImageManager', 'createdBy');
              $this->dropColumn('ImageManager', 'modifiedBy');
          }
      }