Added item_id foreign key column in sticker mapping master table #1067

Merged
jothi merged 1 commits from ranjith-dev into master 2026-09-21 12:37:18 +00:00

View File

@@ -0,0 +1,33 @@
<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
/**
* Run the migrations.
*/
public function up(): void
{
$sql = <<<'SQL'
ALTER TABLE sticker_mapping_masters
ADD COLUMN item_id BIGINT DEFAULT NULL,
ADD CONSTRAINT sticker_mapping_masters_item_id_fkey
FOREIGN KEY (item_id) REFERENCES items(id);
SQL;
DB::statement($sql);
}
/**
* Reverse the migrations.
*/
public function down(): void
{
// Schema::table('sticker_mapping_masters', function (Blueprint $table) {
// //
// });
}
};