2019_08_21_101106_create_upgrade_table.php 1.1 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. <?php
  2. use Illuminate\Support\Facades\Schema;
  3. use Illuminate\Database\Schema\Blueprint;
  4. use Illuminate\Database\Migrations\Migration;
  5. class CreateUpgradeTable extends Migration
  6. {
  7. /**
  8. * Run the migrations.
  9. *
  10. * @return void
  11. */
  12. public function up()
  13. {
  14. Schema::create('upgrade', function (Blueprint $table) {
  15. $table->bigIncrements('id');
  16. $table->string('os',20)->nullable()->comment('客户端名称');
  17. $table->string('version',50)->nullable()->comment('版本号');
  18. $table->integer('version_code')->default(0)->comment('系统版本构建');
  19. $table->string('url')->nullable()->comment('下载地址');
  20. $table->string('title',100)->comment('标题');
  21. $table->string('content')->comment('说明');
  22. $table->tinyInteger('is_forced_update')->default(0)->comment('是否强制更新 1强制更新');
  23. $table->timestamps();
  24. });
  25. }
  26. /**
  27. * Reverse the migrations.
  28. *
  29. * @return void
  30. */
  31. public function down()
  32. {
  33. Schema::dropIfExists('upgrade');
  34. }
  35. }