<?php

use Illuminate\Support\Facades\Schema;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Database\Migrations\Migration;

class CreateTechnicianPositionTable extends Migration
{
    /**
     * Run the migrations.
     *
     * @return void
     */
    public function up()
    {
        Schema::create('technician_position', function (Blueprint $table) {
            $table->bigIncrements('id');
            $table->bigInteger('technician_id')->comment('技师ID');
            $table->string('longitude')->default('')->comment('经度');
            $table->string('latitude')->default('')->comment('纬度');
            $table->string('nation_code')->nullable()->comment('民族');
            $table->string('city_code')->nullable()->comment('城市编码');
            $table->string('province')->nullable()->comment('省');
            $table->string('city')->nullable()->comment('省');
            $table->string('district')->nullable()->comment('省');
            $table->string('street')->nullable()->comment('街道');
            $table->string('street_number')->nullable()->comment('街道号码');
            $table->string('adcode')->nullable()->comment('城市编码');
            $table->string('district_code')->nullable()->comment('地区编码');
            $table->string('phone_area_code')->nullable()->comment('电话区号');
            $table->string('address')->nullable()->comment('地址');
            $table->timestamps();
            $table->softDeletes();
        });
    }

    /**
     * Reverse the migrations.
     *
     * @return void
     */
    public function down()
    {
        Schema::dropIfExists('technician_position');
    }
}
