]> BookStack Code Mirror - bookstack/blob - database/migrations/2015_07_27_172342_create_chapters_table.php
Making sure MyISAM is set for the tables that need it for new installtions that are...
[bookstack] / database / migrations / 2015_07_27_172342_create_chapters_table.php
1 <?php
2
3 use Illuminate\Database\Schema\Blueprint;
4 use Illuminate\Database\Migrations\Migration;
5
6 class CreateChaptersTable extends Migration
7 {
8     /**
9      * Run the migrations.
10      *
11      * @return void
12      */
13     public function up()
14     {
15         Schema::create('chapters', function (Blueprint $table) {
16             $table->engine = 'MyISAM';
17             $table->increments('id');
18             $table->integer('book_id');
19             $table->string('slug')->indexed();
20             $table->text('name');
21             $table->text('description');
22             $table->integer('priority');
23             $table->nullableTimestamps();
24         });
25     }
26
27     /**
28      * Reverse the migrations.
29      *
30      * @return void
31      */
32     public function down()
33     {
34         Schema::drop('chapters');
35     }
36 }