Conditions | 2 |
Paths | 2 |
Total Lines | 15 |
Code Lines | 12 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 0 |
1 | <?php |
||
19 | public function up() |
||
20 | { |
||
21 | $connection=config('lang-switch.database.connection'); |
||
22 | if (!Schema::connection($connection)->hasTable('_lang_switcher')) { |
||
23 | Schema::connection($connection)->create('_lang_switcher', function (Blueprint $table) { |
||
24 | $table->increments('id'); |
||
25 | $table->string('class', 20)->default(''); |
||
26 | $table->string('method', 20)->default(''); |
||
27 | $table->string('middleware', 20)->default(''); |
||
28 | $table->tinyInteger('enable')->default(1); |
||
29 | |||
30 | $table->index('class', 'class'); |
||
31 | $table->index('method', 'method'); |
||
32 | $table->index('middleware', 'middleware'); |
||
33 | $table->index('enable', 'enable'); |
||
34 | }); |
||
49 |