feat: support multiple vehicle category scopes selection in hse master simper types

This commit is contained in:
Ray1111-aa
2026-10-25 23:21:22 +07:00
parent 01152a4260
commit 58f1801810
8 changed files with 594 additions and 128 deletions
@@ -0,0 +1,34 @@
<?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
{
Schema::table('simper_types', function (Blueprint $table) {
try {
$table->dropIndex('simper_types_category_scope_index');
} catch (\Throwable $e) {
// Ignore jika indeks tidak ada
}
$table->text('category_scope')->change();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::table('simper_types', function (Blueprint $table) {
$table->string('category_scope', 50)->change();
$table->index('category_scope');
});
}
};