id(); $table->string('nama'); $table->boolean('jenis_kelamin'); $table->date('tanggal_lahir'); $table->string('pendidikan_terakhir')->nullable(); $table->string('alamat')->nullable(); $table->foreignId('desa_kelurahan_id')->nullable()->constrained('master_desa_kelurahan'); $table->string('pekerjaan_utama')->nullable(); $table->foreignId('komoditas_id')->nullable()->constrained('master_komoditas'); $table->float('lama_bertani', 8)->nullable(); $table->float('luas_lahan', 8)->nullable(); $table->string('pekerjaan_sampingan')->nullable(); $table->foreignId('komoditas_sampingan_id')->nullable()->constrained('master_komoditas'); $table->float('lama_bertani_sampingan', 8)->nullable(); $table->float('luas_lahan_sampingan', 8)->nullable(); $table->string('status_perkawinan')->nullable(); $table->string('status_keluarga')->nullable(); $table->integer('jumlah_tanggungan')->nullable(); $table->jsonb('petani_pengumpul')->nullable(); $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_petani_cpm'); } };