<?php

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

class CreateBasesgestdocsTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('basesgestdocs', function (Blueprint $table) {
            $table->id();
            $table->string('base')->nullable()->unique();
            // $table->enum('estado',['activo','eliminado']);
            $table->string('nif')->unique()->nullable();
            $table->string('pais')->unique()->nullable();
            $table->string('provincia')->unique()->nullable();
            $table->string('municipio')->unique()->nullable();
            $table->string('bairro')->unique()->nullable();
            $table->string('referencia')->unique()->nullable();
            $table->string('numero')->unique()->nullable();
            $table->softDeletes();
            $table->timestamps();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::table('basesgestdocs', function(Blueprint $table)
        {
            $table->dropSoftDeletes();
        });

        Schema::dropIfExists('basesgestdocs');
    }
}
