Conditions | 1 |
Paths | 1 |
Total Lines | 21 |
Code Lines | 17 |
Lines | 0 |
Ratio | 0 % |
Changes | 0 |
1 | <?php |
||
38 | public function up() |
||
39 | { |
||
40 | $this->createSchema(function(Blueprint $table) { |
||
41 | $table->increments('id'); |
||
42 | $table->unsignedInteger('author_id')->default(0); |
||
43 | $table->unsignedInteger('category_id'); |
||
44 | $table->string('locale', 5)->default(config('app.locale')); |
||
45 | $table->string('title'); |
||
46 | $table->string('slug'); |
||
47 | $table->text('excerpt'); |
||
48 | $table->string('thumbnail')->nullable(); |
||
49 | $table->longtext('content_raw'); |
||
50 | $table->longtext('content_html'); |
||
51 | $table->boolean('is_draft')->default(false); |
||
52 | $table->timestamps(); |
||
53 | $table->timestamp('published_at')->nullable(); |
||
54 | $table->softDeletes(); |
||
55 | |||
56 | $table->unique(['locale', 'slug']); |
||
57 | }); |
||
58 | } |
||
59 | } |
||
60 |