2021_02_05_114911_sys_assemble.php 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. use Illuminate\Database\Migrations\Migration;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Support\Facades\Schema;
  5. return new class extends Migration
  6. {
  7. /**
  8. * eav 集合
  9. * Run the migrations.
  10. *
  11. * @return void
  12. */
  13. public function up()
  14. {
  15. Schema::create('sys_assemble', function (Blueprint $table) {
  16. $table->id('id')->unsigned()->comment('编号');
  17. $table->string('mid', 16)->comment('唯一标识符'); // 随机
  18. $table->string('title', 255)->comment('中文标题'); // 中文标题
  19. $table->string('schema', 255)->unique()->comment('表的名称'); // 表名称
  20. $table->string('remark', 500)->nullable()->comment('备注'); // 备注
  21. $table->bigInteger('connect_db_id',false)->default(1)->comment('备注'); // 备注
  22. $table->tinyInteger('is_delete')->default(0)->comment('是否删除 1 删除');
  23. $table->integer('created_at', false)->unsigned()->comment('创建时间,时间戳');
  24. $table->integer('updated_at', false)->unsigned()->comment('更新时间,时间戳');
  25. });
  26. }
  27. /**
  28. * Reverse the migrations.
  29. *
  30. * @return void
  31. */
  32. public function down()
  33. {
  34. Schema::dropIfExists('sys_assemble');
  35. }
  36. };