<?php
/**
 * ------------------------ 
 *  版权所有  www.tecmz.com
 *  商业版本请购买正版授权使用
 * ------------------------
*/ use Illuminate\Database\Migrations\Migration; use Illuminate\Database\Schema\Blueprint; class CreateMemberAddress extends Migration { public function up() { Schema::create('member_address', function (Blueprint $hTN3M) { $hTN3M->increments('id'); $hTN3M->timestamps(); $hTN3M->integer('userId')->nullable()->comment('用户ID'); $hTN3M->string('name', 20)->nullable()->comment('姓名'); $hTN3M->string('phone', 20)->nullable()->comment('手机号'); $hTN3M->string('area', 100)->nullable()->comment('省市地区'); $hTN3M->string('detail', 200)->nullable()->comment('详细地址'); $hTN3M->string('post', 20)->nullable()->comment('邮政编码'); $hTN3M->tinyInteger('isDefault')->nullable()->comment('默认'); $hTN3M->index(array('userId')); }); } public function down() { } }