37 lines
794 B
PHP
37 lines
794 B
PHP
<?php
|
|
|
|
use Illuminate\Database\Migrations\Migration;
|
|
use Illuminate\Database\Schema\Blueprint;
|
|
use Illuminate\Support\Facades\Schema;
|
|
|
|
class CreateBeersTable extends Migration
|
|
{
|
|
/**
|
|
* Run the migrations.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function up()
|
|
{
|
|
Schema::create('beers', function (Blueprint $table) {
|
|
$table->unsignedBigInteger('id');
|
|
$table->string('beer');
|
|
$table->integer('rating');
|
|
$table->string('country');
|
|
$table->string('type');
|
|
$table->string('review')->nullable();
|
|
$table->timestamps();
|
|
});
|
|
}
|
|
|
|
/**
|
|
* Reverse the migrations.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function down()
|
|
{
|
|
Schema::dropIfExists('beers');
|
|
}
|
|
}
|