erp/database/migrations/2024_07_24_145032_create_suppliers_table.php

42 lines
1.3 KiB
PHP
Raw Normal View History

2024-07-24 17:46:48 +08:00
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateSuppliersTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('suppliers', function (Blueprint $table) {
$table->bigIncrements('id');
2024-08-13 18:17:03 +08:00
$table->string('supplier_name',100)->comment('供应商名称');
2024-07-24 17:46:48 +08:00
$table->string('company_name',100)->nullable()->comment('公司名称');
$table->string('address')->nullable()->comment('地址');
$table->string('link_tel',100)->nullable()->comment('联系方式');
$table->string('payment_account',100)->nullable()->comment('支付方式');
$table->string('supply_type')->nullable()->comment('供应类型');
$table->string('agent_name')->nullable()->comment('开发维护人');
$table->Integer('agent_id')->nullable()->comment('开发维护人id');
2024-07-24 17:46:48 +08:00
$table->index('supplier_name');
$table->timestamps();
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('suppliers');
}
}