form tabel

This commit is contained in:
2026-05-15 15:31:19 +07:00
parent 34d09d03bb
commit e0ab4bdace
24 changed files with 1853 additions and 182 deletions
@@ -0,0 +1,47 @@
<?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::create('ekosistem_basis_data_form', function (Blueprint $table) {
$table->id();
$table->foreignId('tabel_id')->constrained('ekosistem_basis_data_tabel')->restrictOnDelete();
$table->foreignId('parent_id')->nullable()->constrained('ekosistem_basis_data_form')->restrictOnDelete();
$table->enum('tipe', ['form-row', 'form-column', 'form-value', 'form-section', 'form-hr-line'])->default('form-value');
$table->integer('column_width')->nullable();
$table->foreignId('kolom_id')->nullable()->constrained('ekosistem_basis_data_kolom')->nullOnDelete();
$table->string('section_label')->nullable();
$table->integer('urutan')->default(1);
$table->foreignId('created_by')->nullable()->constrained('users')->onDelete('set null');
$table->foreignId('updated_by')->nullable()->constrained('users')->onDelete('set null');
$table->foreignId('deleted_by')->nullable()->constrained('users')->onDelete('set null');
$table->timestamps();
$table->softDeletes();
});
}
/**
* Reverse the migrations.
*/
public function down(): void
{
Schema::dropIfExists('ekosistem_basis_data_form');
}
};