<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ use Illuminate\Database\Schema\Blueprint; use Illuminate\Database\Migrations\Migration; class CreateMemberGroup extends Migration { public function up() { goto RyNJB; o6i_C: Schema::table('member_user', function (Blueprint $onV5E) { $onV5E->integer('groupId')->nullable()->comment(''); }); goto sksQ7; RyNJB: Schema::create('member_group', function (Blueprint $onV5E) { $onV5E->increments('id'); $onV5E->timestamps(); $onV5E->string('title', 50)->nullable()->comment('名称'); $onV5E->string('description', 200)->nullable()->comment('描述'); $onV5E->tinyInteger('isDefault')->nullable()->comment('默认'); }); goto o6i_C; sksQ7: \ModStart\Core\Dao\ModelUtil::insertAll('member_group', array(array('title' => '普通用户', 'description' => '', 'isDefault' => true), array('title' => '高级用户', 'description' => '', 'isDefault' => false))); goto bJwP5; bJwP5: } public function down() { } }