<?php

use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;

return new class extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('manifestation_taches', function (Blueprint $table) {
            $table->id();
            $table->bigInteger('Tache_id')->unsigned()->nullable();
            $table->foreign('Tache_id')->references('id')->on('taches')->nullable();
            $table->bigInteger('manifInteret_id')->unsigned()->nullable();
            $table->foreign('manifInteret_id')->references('id')->on('manifestation_interets')->nullable();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('manifestation_taches');
    }
};
