2020_08_21_145711_create_ss_config_table.php 932 B

12345678910111213141516171819202122232425262728293031323334
  1. <?php
  2. use Illuminate\Database\Migrations\Migration;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Support\Facades\Schema;
  5. class CreateSsConfigTable extends Migration
  6. {
  7. /**
  8. * Run the migrations.
  9. *
  10. * @return void
  11. */
  12. public function up()
  13. {
  14. Schema::create('ss_config', function (Blueprint $table) {
  15. $table->increments('id');
  16. $table->string('name', 50)->comment('配置名');
  17. $table->boolean('type')->default(1)->comment('类型:1-加密方式、2-协议、3-混淆');
  18. $table->boolean('is_default')->default(0)->comment('是否默认:0-不是、1-是');
  19. $table->unsignedTinyInteger('sort')->default(0)->comment('排序:值越大排越前');
  20. });
  21. }
  22. /**
  23. * Reverse the migrations.
  24. *
  25. * @return void
  26. */
  27. public function down()
  28. {
  29. Schema::dropIfExists('ss_config');
  30. }
  31. }