]> BookStack Code Mirror - bookstack/blob - database/migrations/2015_08_09_093534_create_page_revisions_table.php
b8264fd29e6202b0efac265fa60ce0be7dea1cfa
[bookstack] / database / migrations / 2015_08_09_093534_create_page_revisions_table.php
1 <?php
2
3 use Illuminate\Database\Migrations\Migration;
4 use Illuminate\Database\Schema\Blueprint;
5
6 return new class extends Migration
7 {
8     /**
9      * Run the migrations.
10      *
11      * @return void
12      */
13     public function up()
14     {
15         Schema::create('page_revisions', function (Blueprint $table) {
16             $table->increments('id');
17             $table->integer('page_id')->indexed();
18             $table->string('name');
19             $table->longText('html');
20             $table->longText('text');
21             $table->integer('created_by');
22             $table->nullableTimestamps();
23         });
24     }
25
26     /**
27      * Reverse the migrations.
28      *
29      * @return void
30      */
31     public function down()
32     {
33         Schema::drop('page_revisions');
34     }
35 };