eliteregistry/database/migrations/2021_04_06_044648_create_ships_table.php

35 lines
719 B
PHP
Raw Permalink Normal View History

2021-04-07 05:03:54 +00:00
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateShipsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('ships', function (Blueprint $table) {
$table->string('id')->unique;
$table->string('shipId')->unique();
$table->string('shipName');
$table->string('shipOwner');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('ships');
}
}