30 lines
954 B
PHP
30 lines
954 B
PHP
<?php
|
|
|
|
use Hyperf\Database\Schema\Schema;
|
|
use Hyperf\Database\Schema\Blueprint;
|
|
use Hyperf\Database\Migrations\Migration;
|
|
|
|
return new class extends Migration {
|
|
public function up(): void
|
|
{
|
|
Schema::create('cst', function (Blueprint $table) {
|
|
$table->bigIncrements('id');
|
|
$table->string('hashkey', 300)->unique();
|
|
$table->string('name', 255);
|
|
$table->string('phone', 50)->nullable();
|
|
$table->string('email', 255)->nullable();
|
|
$table->unsignedBigInteger('store_id')->nullable();
|
|
$table->unsignedBigInteger('user_id')->nullable();
|
|
$table->unsignedBigInteger('created_by')->nullable();
|
|
$table->unsignedBigInteger('updated_by')->nullable();
|
|
$table->boolean('is_active')->default(true);
|
|
$table->timestamps();
|
|
});
|
|
}
|
|
|
|
public function down(): void
|
|
{
|
|
Schema::dropIfExists('cst');
|
|
}
|
|
};
|