12345678910111213141516171819202122232425262728293031323334353637383940 |
- <?php
- use Illuminate\Support\Facades\Schema;
- use Illuminate\Database\Schema\Blueprint;
- use Illuminate\Database\Migrations\Migration;
- class CreateWarningLogsTable extends Migration
- {
- /**
- * Run the migrations.
- *
- * @return void
- */
- public function up()
- {
- Schema::create('warning_logs', function (Blueprint $table) {
- $table->bigIncrements('id');
- $table->string('box_no', 50)->nullable()->comment('中控编号');
- $table->string('bike_no', 50)->nullable()->comment('车辆编号');
- $table->tinyInteger('type')->default(0)->comment('警告类型');
- $table->text('body')->nullable()->comment('数据');
- $table->text('source_body')->nullable()->comment('原报文数据');
- $table->string('source')->comment('采集来源');
- $table->tinyInteger('error_grade')->default(0)->comment('错误等级');
- $table->timestamps();
- });
- }
- /**
- * Reverse the migrations.
- *
- * @return void
- */
- public function down()
- {
- Schema::dropIfExists('warning_logs');
- }
- }
|