Files
asset-management-system/database/migrations/2025_12_02_000000_create_settings_table.php
2025-12-01 07:53:01 +07:00

28 lines
752 B
PHP

<?php
use Illuminate\Database\Migrations\Migration;
use Illuminate\Database\Schema\Blueprint;
use Illuminate\Support\Facades\Schema;
return new class extends Migration
{
public function up(): void
{
Schema::create('settings', function (Blueprint $table) {
$table->id();
$table->string('key')->unique();
$table->string('group')->nullable();
$table->string('type')->default('string');
$table->text('value')->nullable();
$table->string('description')->nullable();
$table->boolean('is_public')->default(false);
$table->timestamps();
});
}
public function down(): void
{
Schema::dropIfExists('settings');
}
};