Merge branch 'master' of gitlab.com:CIEFWorldwideSdnBhd/exchange-2.0 into supplier-bill-group-dashboard

This commit is contained in:
edmondlang
2024-04-02 11:53:43 +08:00
49 changed files with 513 additions and 49 deletions
@@ -0,0 +1,37 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
class CreateKeyValuePairsTable extends Migration
{
/**
* Run the migrations.
*
* @return void
*/
public function up()
{
Schema::create('key_value_pairs', function (Blueprint $table) {
$table->id();
$table->string('owner_type'); //'user', 'order', 'transaction'
$table->unsignedBigInteger('owner_id');
$table->string('key');
$table->string('value');
$table->timestamps();
$table->index(['owner_type', 'owner_id']);
});
}
/**
* Reverse the migrations.
*
* @return void
*/
public function down()
{
Schema::dropIfExists('key_value_pairs');
}
}