42 lines
1.3 KiB
PHP
42 lines
1.3 KiB
PHP
<?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('supplier', function (Blueprint $table) {
|
|
$table->id();
|
|
$table->string('name')->comment('供应商名');
|
|
$table->string('main_category')->comment('主营大类');
|
|
$table->string('main_product')->comment('主要产品');
|
|
$table->string('website')->nullable()->comment('官网地址');
|
|
$table->string('address')->nullable()->comment('省市区')->change();
|
|
$table->string('detail_address')->nullable()->comment('详细地址')->change();
|
|
$table->string('user_name')->nullable()->comment('联系人');
|
|
$table->char('mobile',11)->comment('联系人手机号');
|
|
$table->tinyInteger('can_see')->default(0)->comment('是否可见 0:全部可见 1:本人可见');
|
|
$table->string('product_ids')->comment('产品id');
|
|
$table->timestamps();
|
|
});
|
|
}
|
|
|
|
/**
|
|
* Reverse the migrations.
|
|
*
|
|
* @return void
|
|
*/
|
|
public function down()
|
|
{
|
|
Schema::dropIfExists('supplier');
|
|
}
|
|
};
|