1234567891011121314151617181920212223242526272829303132333435363738394041424344 |
- <?php
- use Illuminate\Database\Migrations\Migration;
- use Illuminate\Database\Schema\Blueprint;
- use Illuminate\Support\Facades\Schema;
- return new class extends Migration
- {
- /**
- * Run the migrations.
- *
- * @return void
- */
- public function up()
- {
- Schema::create('coach_users', function (Blueprint $table) {
- $table->comment('技师');
- $table->increments('id');
- $table->unsignedBigInteger('user_id')->comment('用户编号');
- $table->unsignedBigInteger('info_record_id')->nullable()->comment('技师信息记录编号');
- $table->unsignedBigInteger('real_auth_record_id')->nullable()->comment('技师实名认证记录编号');
- $table->unsignedBigInteger('qualification_record_id')->nullable()->comment('技师资质认证记录编号');
- $table->unsignedBigInteger('shop_id')->nullable()->comment('店铺编号');
- $table->string('level')->nullable()->comment('技师等级');
- $table->integer('virtual_order')->default(new \Illuminate\Database\Query\Expression('0'))->nullable()->comment('虚拟订单数');
- $table->decimal('score')->default(new \Illuminate\Database\Query\Expression('5.0'))->nullable()->comment('评分');
- $table->string('work_status')->default('REST')->comment('工作状态');
- $table->string('virtual_status')->default('DISABLE')->comment('虚拟状态');
- $table->string('state')->default('ENABLE')->comment('状态');
- $table->timestamps();
- $table->softDeletes();
- });
- }
- /**
- * Reverse the migrations.
- *
- * @return void
- */
- public function down()
- {
- Schema::dropIfExists('coach_users');
- }
- };
|