I want only use created_at , how to do it?
I know:
This can custom timestamps name
const CREATED_AT = \'created\'; const UPDATED_AT = \'updat
My solution:
class CreatePostsTable extends Migration { public function up() { Schema::create('posts', function(Blueprint $table){ $table->timestamp('created_at')->default(DB::raw('CURRENT_TIMESTAMP')); }); }
This works for me