| 1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- <?php
- use Illuminate\Support\Facades\Schema;
- use Illuminate\Database\Schema\Blueprint;
- use Illuminate\Database\Migrations\Migration;
- /**
- * Migration auto-generated by Sequel Pro Laravel Export
- * @see https://github.com/cviebrock/sequel-pro-laravel-export
- */
- class CreateUserTemplateTable extends Migration
- {
- /**
- * Run the migrations.
- *
- * @return void
- */
- public function up()
- {
- Schema::create('user_template', function (Blueprint $table) {
- $table->increments('id');
- $table->integer('user_id')->comment('用户id');
- $table->string('app_id')->comment('app_id')->default(0);
- $table->integer('template_id')->comment('模板id');
- $table->nullableTimestamps();
- $table->index('template_id', 'user_template_template_id_foreign');
- $table->index('app_id', 'user_template_app_id_foreign');
-
- });
- }
- /**
- * Reverse the migrations.
- *
- * @return void
- */
- public function down()
- {
- Schema::dropIfExists('user_template');
- }
- }
|