Update Active Status and Fix Mode 3

This commit is contained in:
2022-07-25 12:24:55 +07:00
parent d7de76798e
commit 2493e7fd2a
14 changed files with 118 additions and 14 deletions

View File

@@ -0,0 +1,44 @@
<?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('member_plans', function (Blueprint $table) {
$table->id();
$table->string('member_id');
$table->string('plan_id');
$table->string('status')->default('active');
$table->dateTime('start')->nullable();
$table->dateTime('end')->nullalbe();
$table->timestamps();
$table->softDeletes();
$table->unsignedBigInteger('created_by')->nullable();
$table->unsignedBigInteger('updated_by')->nullable();
$table->unsignedBigInteger('deleted_by')->nullable();
$table->index(['policy_id', 'member_id']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('member_plans');
}
};