@@ -14,8 +14,8 @@ |
||
14 | 14 | $table->string('body', 4000); |
15 | 15 | $table->integer('forum_id')->unsigned(); |
16 | 16 | $table->foreign('forum_id') |
17 | - ->references('id')->on('forums') |
|
18 | - ->onDelete('cascade'); |
|
17 | + ->references('id')->on('forums') |
|
18 | + ->onDelete('cascade'); |
|
19 | 19 | $table->integer('author_id'); |
20 | 20 | $table->timestamps(); |
21 | 21 | }); |
@@ -8,7 +8,7 @@ |
||
8 | 8 | public function up() |
9 | 9 | { |
10 | 10 | if (!Schema::hasTable('forum_posts')) { |
11 | - Schema::create('forum_posts', function ($table) { |
|
11 | + Schema::create('forum_posts', function($table) { |
|
12 | 12 | $table->increments('id'); |
13 | 13 | $table->string('title'); |
14 | 14 | $table->string('body', 4000); |
@@ -13,8 +13,8 @@ |
||
13 | 13 | $table->string('body', 4000); |
14 | 14 | $table->integer('post_id')->unsigned(); |
15 | 15 | $table->foreign('post_id') |
16 | - ->references('id')->on('forum_posts') |
|
17 | - ->onDelete('cascade'); |
|
16 | + ->references('id')->on('forum_posts') |
|
17 | + ->onDelete('cascade'); |
|
18 | 18 | $table->integer('author_id'); |
19 | 19 | $table->timestamps(); |
20 | 20 | }); |
@@ -8,7 +8,7 @@ |
||
8 | 8 | public function up() |
9 | 9 | { |
10 | 10 | if (!Schema::hasTable('forum_post_replies')) { |
11 | - Schema::create('forum_post_replies', function ($table) { |
|
11 | + Schema::create('forum_post_replies', function($table) { |
|
12 | 12 | $table->increments('id'); |
13 | 13 | $table->string('body', 4000); |
14 | 14 | $table->integer('post_id')->unsigned(); |
@@ -8,7 +8,7 @@ discard block |
||
8 | 8 | public function up() |
9 | 9 | { |
10 | 10 | if (!Schema::hasColumn('forum_posts', 'sticky') && !Schema::hasColumn('forum_posts', 'locked')) { |
11 | - Schema::table('forum_posts', function ($table) { |
|
11 | + Schema::table('forum_posts', function($table) { |
|
12 | 12 | $table->boolean('sticky')->default(0); |
13 | 13 | $table->boolean('locked')->default(0); |
14 | 14 | }); |
@@ -17,8 +17,8 @@ discard block |
||
17 | 17 | |
18 | 18 | public function down() |
19 | 19 | { |
20 | - Schema::table('forum_posts', function ($table) { |
|
21 | - $table->dropColumn(['sticky', 'locked']); |
|
20 | + Schema::table('forum_posts', function($table) { |
|
21 | + $table->dropColumn([ 'sticky', 'locked' ]); |
|
22 | 22 | }); |
23 | 23 | } |
24 | 24 | } |
@@ -14,8 +14,8 @@ |
||
14 | 14 | $table->string('description')->nullable(); |
15 | 15 | $table->integer('category_id')->unsigned(); |
16 | 16 | $table->foreign('category_id') |
17 | - ->references('id')->on('forum_categories') |
|
18 | - ->onDelete('cascade'); |
|
17 | + ->references('id')->on('forum_categories') |
|
18 | + ->onDelete('cascade'); |
|
19 | 19 | $table->integer('public')->default(1); |
20 | 20 | $table->timestamps(); |
21 | 21 | }); |
@@ -8,7 +8,7 @@ |
||
8 | 8 | public function up() |
9 | 9 | { |
10 | 10 | if (!Schema::hasTable('forums')) { |
11 | - Schema::create('forums', function ($table) { |
|
11 | + Schema::create('forums', function($table) { |
|
12 | 12 | $table->increments('id'); |
13 | 13 | $table->string('name'); |
14 | 14 | $table->string('description')->nullable(); |