%PDF- %PDF-
Direktori : /var/www/html/geotechnics/api/database/migrations/ |
Current File : /var/www/html/geotechnics/api/database/migrations/2019_12_26_181454_create_reciptions_table.php |
<?php use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; use Illuminate\Support\Facades\Schema; class CreateReciptionsTable extends Migration { /** * Run the migrations. * * @return void */ public function up() { Schema::create('reciptions', function (Blueprint $table) { $table->bigIncrements('id'); $table->unsignedBigInteger('project_id') ->index(); $table->foreign('project_id') ->references('id') ->on('projects'); $table->unsignedBigInteger('user_id') ->index(); $table->foreign('user_id') ->references('id') ->on('users'); $table->dateTime('last_read_at'); $table->timestamps(); }); } /** * Reverse the migrations. * * @return void */ public function down() { Schema::dropIfExists('reciptions'); } }