m170828_075235_create_district_table::up()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 5

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 5
rs 10
c 0
b 0
f 0
cc 1
nc 1
nop 0
1
<?php
2
3
use yii\db\Migration;
4
5
/**
6
 * Handles the creation of table `district`.
7
 */
8
class m170828_075235_create_district_table extends Migration
9
{
10
    /**
11
     * @inheritdoc
12
     * @see https://github.com/eduosi/district/blob/master/district-standard.sql
13
     */
14
    public function up()
15
    {
16
        $this->execute(file_get_contents('https://raw.githubusercontent.com/eduosi/district/master/district-full.sql'));
17
        //$this->execute(file_get_contents('https://raw.githubusercontent.com/eduosi/district/master/district-standard.sql'));
18
    }
19
20
    /**
21
     * @inheritdoc
22
     */
23
    public function down()
24
    {
25
        $this->dropTable('district');
26
    }
27
}
28