Your ROOT_URL in app.ini is http://159.89.207.79:3000/ but you are visiting http://9.cron.my.id:3000/mahesh/voyager-cms/blame/commit/71c632616b0c4250404c56af80e3dd30efc5ce22/database/migrations/2016_01_01_000000_create_posts_table.php You should set ROOT_URL correctly, otherwise the web may not work correctly.

46 lines
1.2 KiB

2 years ago
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
class CreatePostsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
// Create table for storing roles
Schema::create('posts', function (Blueprint $table) {
$table->increments('id');
$table->integer('author_id');
$table->integer('category_id')->nullable();
$table->string('title');
$table->string('seo_title')->nullable();
$table->text('excerpt');
$table->text('body');
$table->string('image')->nullable();
$table->string('slug')->unique();
$table->text('meta_description');
$table->text('meta_keywords');
$table->enum('status', ['PUBLISHED', 'DRAFT', 'PENDING'])->default('DRAFT');
$table->boolean('featured')->default(0);
$table->timestamps();
//$table->foreign('author_id')->references('id')->on('users');
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('posts');
}
}