/home/mip/mip/database/migrations/likod/2016_05_16_081403_create_client_modules_table.php
<?php
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;
class CreateClientModulesTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('client_modules', function (Blueprint $table) {
$table->engine = 'MYISAM';
$table->increments('id');
$table->string('title', 100);
$table->string('link_type', 20)->default('Parent');
$table->integer('page_id')->unsigned()->index();
$table->string('module_name', 50);
$table->string('module_description', 255);
$table->string('url', 255);
$table->string('uri', 255);
$table->string('icon', 50);
$table->integer('menu_group_id')->unsigned()->index();
$table->integer('position')->unsigned()->index();
$table->string('target', 10);
$table->integer('parent_id')->unsigned()->index();
$table->tinyInteger('is_parent')->unsigned()->index();
$table->tinyInteger('has_parent')->unsigned()->index();
$table->enum('show_menu', ['0', '1'])->default('1');
$table->tinyInteger('has_read')->unsigned()->index();
$table->tinyInteger('has_create')->unsigned()->index();
$table->tinyInteger('has_update')->unsigned()->index();
$table->tinyInteger('has_delete')->unsigned()->index();
$table->tinyInteger('has_export')->unsigned()->index();
$table->tinyInteger('has_import')->unsigned()->index();
$table->tinyInteger('has_print')->unsigned()->index();
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::drop('client_modules');
}
}