<?php

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

class CreatingPermissionsColumnsWithoutIndex extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::table('permissions', function (Blueprint $table) {
            $table->string('flag_meaning', 100)->after('id')
            ->comment('Nombre de la vista a dar permisos');
            $table->smallInteger('default_permission')->default('1')->after('flag_meaning')
            ->comment('Permiso por defecto de la vista');
        });
    }

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