update semua form inspeksi
This commit is contained in:
@@ -169,7 +169,7 @@ class SurveyorController extends Controller
|
||||
$rules = $this->getActionSpecificRules($data, $action, $request);
|
||||
|
||||
$inspeksi = Inspeksi::where('permohonan_id', $request->input('permohonan_id'))->where('jenis_jaminan_id', $request->input('jenis_jaminan_id'))->first();
|
||||
if ($request->input('permohonan_id') == $inspeksi->permohonan_id && $request->input('jenis_jaminan_id') == $inspeksi->jenis_jaminan_id) {
|
||||
if ($inspeksi) {
|
||||
$inspeksi->update(['data_form' => json_encode($rules)]);
|
||||
} else {
|
||||
Inspeksi::create([
|
||||
@@ -228,7 +228,6 @@ class SurveyorController extends Controller
|
||||
|
||||
public function storeDenah(Request $request)
|
||||
{
|
||||
|
||||
try {
|
||||
$validatedData = $request->validate([
|
||||
'foto_denah' => 'required|image|mimes:jpeg,png,jpg,gif,svg|max:2048',
|
||||
@@ -239,31 +238,33 @@ class SurveyorController extends Controller
|
||||
|
||||
$validatedData['foto_denah'] = $this->uploadFile($request->file('foto_denah'), 'foto_denah');
|
||||
|
||||
|
||||
$formatJsonDenah = [
|
||||
'foto_denah' => $validatedData['foto_denah'],
|
||||
'luas' => $validatedData['luas'],
|
||||
];
|
||||
|
||||
|
||||
$inspeksi = Inspeksi::where('permohonan_id', $request->input('permohonan_id'))->where('jenis_jaminan_id', $request->input('jenis_jaminan_id'))->first();
|
||||
if ($request->input('permohonan_id') == $inspeksi->permohonan_id && $request->input('jenis_jaminan_id') == $inspeksi->jenis_jaminan_id) {
|
||||
$inspeksi = Inspeksi::where('permohonan_id', $request->input('permohonan_id'))
|
||||
->where('jenis_jaminan_id', $request->input('jenis_jaminan_id'))
|
||||
->first();
|
||||
|
||||
if ($inspeksi) {
|
||||
$inspeksi->update([
|
||||
'denah_form' => json_encode($formatJsonDenah)
|
||||
]);
|
||||
} else {
|
||||
Inspeksi::create([
|
||||
'permohonan_id' => $request->input('permohonan_id'),
|
||||
'denah_form' => json_encode($formatFotojson)
|
||||
'jenis_jaminan_id' => $request->input('jenis_jaminan_id'),
|
||||
'denah_form' => json_encode($formatJsonDenah)
|
||||
]);
|
||||
}
|
||||
|
||||
return response()->json(['success' => true, 'message' => 'Data berhasil disimpan',
|
||||
'data' => $formatJsonDenah], 200);
|
||||
'data' => $formatJsonDenah], 200);
|
||||
} catch (Exception $e) {
|
||||
return response()->json(['success' => false, 'message' => 'Data gagal disimpan: ' . $e->getMessage()], 500);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
||||
@@ -371,19 +372,21 @@ class SurveyorController extends Controller
|
||||
'foto_lantai_lainnya' => $foto_lantai_lainnya,
|
||||
'foto_rute_lainnya' => $foto_rute_lainnya,
|
||||
'basement' => $basement,
|
||||
'gerbang' => $gerbang,
|
||||
'foto_gerbang' => $gerbang,
|
||||
'pendamping' => $pendamping
|
||||
];
|
||||
|
||||
$inspeksi = Inspeksi::where('permohonan_id', $request->input('permohonan_id'))->where('jenis_jaminan_id', $request->input('jenis_jaminan_id'))->first();
|
||||
if ($request->input('permohonan_id') == $inspeksi->permohonan_id && $request->input('jenis_jaminan_id') == $inspeksi->jenis_jaminan_id) {
|
||||
|
||||
if ($inspeksi) {
|
||||
$inspeksi->update([
|
||||
'foto_form' => json_encode($formatFotojson)
|
||||
]);
|
||||
} else {
|
||||
Inspeksi::create([
|
||||
'permohonan_id' => $request->input('permohonan_id'),
|
||||
'foto_form' => json_encode($formatFotojson)
|
||||
'foto_form' => json_encode($formatFotojson),
|
||||
'jenis_jaminan_id' => $request->input('jenis_jaminan_id')
|
||||
]);
|
||||
}
|
||||
|
||||
@@ -645,7 +648,7 @@ class SurveyorController extends Controller
|
||||
* Data pembanding.
|
||||
*/
|
||||
|
||||
public function dataPembanding($id)
|
||||
public function dataPembanding($id, $jaminanId)
|
||||
{
|
||||
$permohonan = Permohonan::with(
|
||||
[
|
||||
@@ -663,7 +666,15 @@ class SurveyorController extends Controller
|
||||
$branches = Branch::all();
|
||||
$provinces = Province::all();
|
||||
|
||||
return view('lpj::surveyor.detail', compact('permohonan', 'surveyor', 'branches', 'provinces'));
|
||||
|
||||
$inpeksi = Inspeksi::where('permohonan_id', $id)->where('jenis_jaminan_id', $jaminanId)->first();
|
||||
$forminspeksi = null;
|
||||
if ($inpeksi) {
|
||||
$forminspeksi = json_decode($inpeksi->data_form, true);
|
||||
}
|
||||
|
||||
// return response()->json($forminspeksi);
|
||||
return view('lpj::surveyor.components.data-pembanding', compact('permohonan', 'surveyor', 'branches', 'provinces'));
|
||||
}
|
||||
|
||||
|
||||
@@ -1238,49 +1249,363 @@ class SurveyorController extends Controller
|
||||
unlink($fullPath);
|
||||
}
|
||||
}
|
||||
private function getKapalData($data): array
|
||||
|
||||
|
||||
private function getKapalData($data, $request): array
|
||||
{
|
||||
return [
|
||||
'keterangan' => $data['keterangan']
|
||||
];
|
||||
}
|
||||
|
||||
private function getKendaraanData($data): array
|
||||
{
|
||||
return [
|
||||
'keterangan' => $data['keterangan']
|
||||
];
|
||||
}
|
||||
|
||||
private function getMesinData($data): array
|
||||
{
|
||||
return [
|
||||
'keterangan' => $data['keterangan']
|
||||
];
|
||||
}
|
||||
|
||||
private function getPesawatData($data): array
|
||||
{
|
||||
return [
|
||||
'keterangan' => $data['keterangan']
|
||||
'action' => $data['action'] ?? null,
|
||||
'nama_wakil_debitur' => $data['nama_wakil_debitur'] ?? null,
|
||||
'hub_calon_debitur' => $data['hub_calon_debitur'] ?? null,
|
||||
'dermaga' => $data['dermaga'] ?? null,
|
||||
'desa_kelurahan' => $data['desa_kelurahan'] ?? null,
|
||||
'kecamatan' => $data['kecamatan'] ?? null,
|
||||
'kota_madya' => $data['kota_madya'] ?? null,
|
||||
'provinsi' => $data['provinsi'] ?? null,
|
||||
'jenis' => $data['jenis'] ?? null,
|
||||
'size' => $data['size'] ?? null,
|
||||
'kondisi' => $data['kondisi'] ?? null,
|
||||
'klasifikasi' => $data['klasifikasi'] ?? null,
|
||||
|
||||
'nama_kapal' => $data['nama_kapal'] ?? null,
|
||||
'pemilik_kapal' => $data['pemilik_kapal'] ?? null,
|
||||
'bendera' => $data['bendera'] ?? null,
|
||||
'nomor_selar' => $data['nomor_selar'] ?? null,
|
||||
'kapal' => $data['kapal'] ?? null,
|
||||
'galangan_kapal' => $data['galangan_kapal'] ?? null,
|
||||
'kapal_shipyard' => $data['kapal_shipyard'] ?? null,
|
||||
'tahun_pembuatan' => $data['tahun_pembuatan'] ?? null,
|
||||
'tahun_launcing' => $data['tahun_launcing'] ?? null,
|
||||
'dwt' => $data['dwt'] ?? null,
|
||||
'lwt' => $data['lwt'] ?? null,
|
||||
'gross_tonnage' => $data['gross_tonnage'] ?? null,
|
||||
'net_tonnage' => $data['net_tonnage'] ?? null,
|
||||
'tenaga_mesin' => $data['tenaga_mesin'] ?? null,
|
||||
'loa' => $data['loa'] ?? null,
|
||||
'lbp' => $data['lbp'] ?? null,
|
||||
'beam' => $data['beam'] ?? null,
|
||||
'depth' => $data['depth'] ?? null,
|
||||
'draft' => $data['draft'] ?? null,
|
||||
|
||||
'lambung_kapal' => $data['lambung_kapal'] ?? null,
|
||||
'dek' => $data['dek'] ?? null,
|
||||
'struktur_rangka' => $data['struktur_rangka'] ?? null,
|
||||
'palka' => $data['palka'] ?? null,
|
||||
'pondasi_mesin' => $data['pondasi_mesin'] ?? null,
|
||||
'area_mesin' => $data['area_mesin'] ?? null,
|
||||
'cat_dan_korosi' => $data['cat_dan_korosi'] ?? null,
|
||||
'sistem_pengelasan' => $data['sistem_pengelasan'] ?? null,
|
||||
'deskripsi_struktur' => $data['deskripsi_struktur'] ?? null,
|
||||
|
||||
'sekoci' => $data['sekoci'] ?? null,
|
||||
'jaket_pelampung' => $data['jaket_pelampung'] ?? null,
|
||||
'alat_pemadaman' => $data['alat_pemadaman'] ?? null,
|
||||
'rambu_darurat' => $data['rambu_darurat'] ?? null,
|
||||
'sistem_alarm' => $data['sistem_alarm'] ?? null,
|
||||
'sistem_pencegah' => $data['sistem_pencegah'] ?? null,
|
||||
'kebakaran' => $data['kebakaran'] ?? null,
|
||||
'lampu_darurat' => $data['lampu_darurat'] ?? null,
|
||||
'deskripsi_peralatan' => $data['deskripsi_peralatan'] ?? null,
|
||||
|
||||
'gps' => $data['gps'] ?? null,
|
||||
'radar' => $data['radar'] ?? null,
|
||||
'radio_komunikasi' => $data['radio_komunikasi'] ?? null,
|
||||
'lampu_navigasi' => $data['lampu_navigasi'] ?? null,
|
||||
'sistem_kendali_otomatis' => $data['sistem_kendali_otomatis'] ?? null,
|
||||
'kompas' => $data['kompas'] ?? null,
|
||||
'deskripsi_navigasi' => $data['deskripsi_navigasi'] ?? null,
|
||||
|
||||
'mesin_utama' => $data['mesin_utama'] ?? null,
|
||||
'mesin_bantu' => $data['mesin_bantu'] ?? null,
|
||||
'pompa_pendingin' => $data['pompa_pendingin'] ?? null,
|
||||
'sistem_pelumasan' => $data['sistem_pelumasan'] ?? null,
|
||||
'propeller' => $data['propeller'] ?? null,
|
||||
'sistem_kelistrikan' => $data['sistem_kelistrikan'] ?? null,
|
||||
'deskripsi_mesin_penggerak' => $data['deskripsi_mesin_penggerak'] ?? null,
|
||||
|
||||
'lampu_navigasi' => $data['lampu_navigasi'] ?? null,
|
||||
'sistem_penerangan' => $data['sistem_penerangan'] ?? null,
|
||||
'sistem_panel_distribusi' => $data['sistem_panel_distribusi'] ?? null,
|
||||
'kabel_perangkat' => $data['kabel_perangkat'] ?? null,
|
||||
'deskripsi_kelistrikan' => $data['deskripsi_kelistrikan'] ?? null,
|
||||
|
||||
'kebersihan_dek_luar' => $data['kebersihan_dek_luar'] ?? null,
|
||||
'tangki_limbah' => $data['tangki_limbah'] ?? null,
|
||||
'sistem_pengelolaan_limbah' => $data['sistem_pengelolaan_limbah'] ?? null,
|
||||
'pengelolaan_air_ballast' => $data['pengelolaan_air_ballast'] ?? null,
|
||||
'deskripsi_kebersihan' => $data['deskripsi_kebersihan'] ?? null,
|
||||
|
||||
'fakta_positif' => $data['fakta_positif'] ?? null,
|
||||
'fakta_negatif' => $data['fakta_negatif'] ?? null,
|
||||
'analisa_makro' => $data['analisa_makro'] ?? null,
|
||||
'kesimpulan' => $data['kesimpulan'] ?? null,
|
||||
'catatan' => $data['catatan'] ?? null,
|
||||
];
|
||||
}
|
||||
public function getKendaraanData($data, $request): array
|
||||
{
|
||||
return [
|
||||
'action' => $data['action'] ?? null,
|
||||
'tanggal_survey' => $data['tanggal_survey'] ?? null,
|
||||
'nama_wakil' => $data['nama_wakil'] ?? null,
|
||||
'hub_calon_debitur' => $data['hub_calon_debitur'] ?? null,
|
||||
'nama_jalan' => $data['nama_jalan'] ?? null,
|
||||
'perumahan_gang' => $data['perumahan_gang'] ?? null,
|
||||
'blok_nomor' => $data['blok_nomor'] ?? null,
|
||||
'desa_kelurahan' => $data['desa_kelurahan'] ?? null,
|
||||
'kecamatan' => $data['kecamatan'] ?? null,
|
||||
'kota_madya' => $data['kota_madya'] ?? null,
|
||||
'provinsi' => $data['provinsi'] ?? null,
|
||||
'kondisi' => $data['kondisi'] ?? null,
|
||||
'nomor_polisi' => $data['nomor_polisi'] ?? null,
|
||||
'nomor_polis_tidak_sesuai' => $data['nomor_polis_tidak_sesuai'] ?? null,
|
||||
'merek' => $data['merek'] ?? null,
|
||||
'merek_tidak_sesuai' => $data['merek_tidak_sesuai'] ?? null,
|
||||
'warna' => $data['warna'] ?? null,
|
||||
'warna_tidak_sesuai' => $data['warna_tidak_sesuai'] ?? null,
|
||||
'nomor_rangka' => $data['nomor_rangka'] ?? null,
|
||||
'nomor_rangka_tidak_sesuai' => $data['nomor_rangka_tidak_sesuai'] ?? null,
|
||||
'nomor_mesin' => $data['nomor_mesin'] ?? null,
|
||||
'nomor_mesin_tidak_sesuai' => $data['nomor_mesin_tidak_sesuai'] ?? null,
|
||||
'posisi_kilometer' => $data['posisi_kilometer'] ?? null,
|
||||
'transmisi' => $data['transmisi'] ?? null,
|
||||
|
||||
|
||||
private function getAlatBeratData($data): array
|
||||
{
|
||||
return [
|
||||
'keterangan' => $data['keterangan']
|
||||
];
|
||||
}
|
||||
'mesin_panel_instrument' => $data['mesin_panel_instrument'] ?? null,
|
||||
'fungsi_mesin_panel_instrument' => $data['fungsi_mesin_panel_instrument'] ?? null,
|
||||
'interior' => $data['interior'] ?? null,
|
||||
'interior' => $data['interior'] ?? null,
|
||||
|
||||
'jumlah_pintu' => $data['jumlah_pintu'] ?? null,
|
||||
'rangka_karoseri' => $data['rangka_karoseri'] ?? null,
|
||||
'ban' => $data['ban'] ?? null,
|
||||
'velg' => $data['velg'] ?? null,
|
||||
'bamper_depan' => $data['bamper_depan'] ?? null,
|
||||
'bamper_belakang' => $data['bamper_belakang'] ?? null,
|
||||
'lampu_depan' => $data['lampu_depan'] ?? null,
|
||||
'lampu_belakang' => $data['lampu_belakang'] ?? null,
|
||||
'kaca_kendaraan' => $data['kaca_kendaraan'] ?? null,
|
||||
'air_conditioner' => $data['air_conditioner'] ?? null,
|
||||
'tape_radio_cd' => $data['tape_radio_cd'] ?? null,
|
||||
'sensor_parkir' => $data['sensor_parkir'] ?? null,
|
||||
'sensor_camera_recorder' => $data['sensor_camera_recorder'] ?? null,
|
||||
'lcd' => $data['lcd'] ?? null,
|
||||
'sabuk_keselamatan' => $data['sabuk_keselamatan'] ?? null,
|
||||
'airbag' => $data['airbag'] ?? null,
|
||||
'asuransi' => $data['asuransi'] ?? null,
|
||||
'perusahaan_asuransi' => $data['perusahaan_asuransi'] ?? null,
|
||||
'tahun_berakhir' => $data['tahun_berakhir'] ?? null,
|
||||
|
||||
|
||||
private function getUnitData($data): array
|
||||
{
|
||||
return [
|
||||
'keterangan' => $data['keterangan']
|
||||
];
|
||||
}
|
||||
'fakta_positif' => $data['fakta_positif'] ?? null,
|
||||
'fakta_negatif' => $data['fakta_negatif'] ?? null,
|
||||
'analisa_makro' => $data['analisa_makro'] ?? null,
|
||||
'kesimpulan' => $data['kesimpulan'] ?? null,
|
||||
'catatan' => $data['catatan'] ?? null,
|
||||
];
|
||||
}
|
||||
|
||||
public function getMesinData($data, $request): array
|
||||
{
|
||||
return [
|
||||
'action' => $data['action'] ?? null,
|
||||
'nama_wakil' => $data['nama_wakil'] ?? null,
|
||||
'nama_jalan' => $data['nama_jalan'] ?? null,
|
||||
'perumahan_gang' => $data['perumahan_gang'] ?? null,
|
||||
'blok' => $data['blok'] ?? null,
|
||||
'desa_kelurahan' => $data['desa_kelurahan'] ?? null,
|
||||
'kecamatan' => $data['kecamatan'] ?? null,
|
||||
'kota_madya' => $data['kota_madya'] ?? null,
|
||||
'provinsi' => $data['provinsi'] ?? null,
|
||||
'hub_calon_debitur' => $data['hub_calon_debitur'] ?? null,
|
||||
'tipe_model' => $data['tipe_model'] ?? null,
|
||||
'merek' => $data['merek'] ?? null,
|
||||
'tahun_pembuatan' => $data['tahun_pembuatan'] ?? null,
|
||||
'negara_pembuat' => $data['negara_pembuat'] ?? null,
|
||||
'kondisi_mesin' => $data['kondisi_mesin'] ?? null,
|
||||
'faktor_positif' => $data['faktor_positif'] ?? null,
|
||||
'faktor_negatif' => $data['faktor_negatif'] ?? null,
|
||||
'kesimpulan' => $data['kesimpulan'] ?? null,
|
||||
'catatan' => $data['catatan'] ?? null,
|
||||
];
|
||||
}
|
||||
|
||||
public function getAlatBeratData($data, $request): array
|
||||
{
|
||||
return [
|
||||
'action' => $data['action'] ?? null,
|
||||
'tanggal_survey' => $data['tanggal_survey'] ?? null,
|
||||
'nama_wakil' => $data['nama_wakil'] ?? null,
|
||||
'hub_calon_debitur' => $data['hub_calon_debitur'] ?? null,
|
||||
'dengan_wadeb' => $data['dengan_wadeb'] ?? null,
|
||||
'nama_jalan' => $data['nama_jalan'] ?? null,
|
||||
'perumahan_gang' => $data['perumahan_gang'] ?? null,
|
||||
'blok' => $data['blok'] ?? null,
|
||||
'desa_kelurahan' => $data['desa_kelurahan'] ?? null,
|
||||
'kecamatan' => $data['kecamatan'] ?? null,
|
||||
'kota_madya' => $data['kota_madya'] ?? null,
|
||||
'provinsi' => $data['provinsi'] ?? null,
|
||||
'jenis_model' => $data['jenis_model'] ?? null,
|
||||
'nomor_lambung' => $data['nomor_lambung'] ?? null,
|
||||
'model_unit' => $data['model_unit'] ?? null,
|
||||
'tahun_pembuatan' => $data['tahun_pembuatan'] ?? null,
|
||||
'merk' => $data['merk'] ?? null,
|
||||
'negara_pembuat' => $data['negara_pembuat'] ?? null,
|
||||
'tahun_pembelian' => $data['tahun_pembelian'] ?? null,
|
||||
'nomor_faktur' => $data['nomor_faktur'] ?? null,
|
||||
'nomor_kontrak' => $data['nomor_kontrak'] ?? null,
|
||||
'nama_pemilik' => $data['nama_pemilik'] ?? null,
|
||||
'alamat_pemilik' => $data['alamat_pemilik'] ?? null,
|
||||
'nomor_asuransi' => $data['nomor_asuransi'] ?? null,
|
||||
'nomor_rangka' => $data['nomor_rangka'] ?? null,
|
||||
'nomor_mesin' => $data['nomor_mesin'] ?? null,
|
||||
'hour_mesters' => $data['hour_mesters'] ?? null,
|
||||
'overhaul_mesin' => $data['overhaul_mesin'] ?? null,
|
||||
|
||||
'mesin_panel' => $data['mesin_panel'] ?? null,
|
||||
'fungsi_panel' => $data['fungsi_panel'] ?? null,
|
||||
'interior' => $data['interior'] ?? null,
|
||||
'rangka_Karoseri' => $data['rangka_Karoseri'] ?? null,
|
||||
'ban' => $data['ban'] ?? null,
|
||||
'velg' => $data['velg'] ?? null,
|
||||
'air_conditioner' => $data['air_conditioner'] ?? null,
|
||||
'aksesoris' => $data['aksesoris'] ?? null,
|
||||
'lcd' => $data['lcd'] ?? null,
|
||||
'perlengkapan' => $data['perlengkapan'] ?? null,
|
||||
'asuransi' => $data['asuransi'] ?? null,
|
||||
'perusahaan_asuransi' => $data['perusahaan_asuransi'] ?? null,
|
||||
'tahun_berakhir' => $data['tahun_berakhir'] ?? null,
|
||||
'sensor_kamera' => $data['sensor_kamera'] ?? null,
|
||||
'sabuk_keselamatan' => $data['sabuk_keselamatan'] ?? null,
|
||||
'air_bag' => $data['air_bag'] ?? null,
|
||||
|
||||
'faktor_positif' => $data['faktor_positif'] ?? null,
|
||||
'faktor_negatif' => $data['faktor_negatif'] ?? null,
|
||||
'kesimpulan' => $data['kesimpulan'] ?? null,
|
||||
'catatan' => $data['catatan'] ?? null,
|
||||
];
|
||||
}
|
||||
|
||||
private function getPesawatData($data, $request): array
|
||||
{
|
||||
return [
|
||||
'action' => $data['action'] ?? null,
|
||||
'tanggal_survey' => $data['tanggal_survey'] ?? null,
|
||||
'nama_wakil' => $data['nama_wakil'] ?? null,
|
||||
'hub_calon_debitur' => $data['hub_calon_debitur'] ?? null,
|
||||
'bandara' => $data['bandara'] ?? null,
|
||||
'desa_kelurahan' => $data['desa_kelurahan'] ?? null,
|
||||
'kecamatan' => $data['kecamatan'] ?? null,
|
||||
'kota_madya' => $data['kota_madya'] ?? null,
|
||||
'provinsi' => $data['provinsi'] ?? null,
|
||||
|
||||
'jenis_pesawat' => $data['jenis_pesawat'] ?? null,
|
||||
'size' => $data['size'] ?? null,
|
||||
'kondisi' => $data['kondisi'] ?? null,
|
||||
'nama_pesawat' => $data['nama_pesawat'] ?? null,
|
||||
'model' => $data['model'] ?? null,
|
||||
'nomor_registrasi' => $data['nomor_registrasi'] ?? null,
|
||||
'tahun_pembuatan' => $data['tahun_pembuatan'] ?? null,
|
||||
'certificate_of_airworthines' => $data['certificate_of_airworthines'] ?? null,
|
||||
'certificate_of_registration' => $data['certificate_of_registration'] ?? null,
|
||||
'total_service_hours' => $data['total_service_hours'] ?? null,
|
||||
'total_service_cycles' => $data['total_service_cycles'] ?? null,
|
||||
|
||||
'last_a_check' => $data['last_a_check'] ?? null,
|
||||
'next_a_check' => $data['next_a_check'] ?? null,
|
||||
'last_b_check' => $data['last_b_check'] ?? null,
|
||||
'next_b_check' => $data['next_b_check'] ?? null,
|
||||
'last_c_check' => $data['last_c_check'] ?? null,
|
||||
'next_c_check' => $data['next_c_check'] ?? null,
|
||||
'next_d_check' => $data['next_d_check'] ?? null,
|
||||
'last_d_check' => $data['last_d_check'] ?? null,
|
||||
'deskripsi_maintenence' => $data['deskripsi_maintenence'] ?? null,
|
||||
|
||||
'instrument_landing_system' => $data['instrument_landing_system'] ?? null,
|
||||
'traffic_collision_avoidance_system' => $data['traffic_collision_avoidance_system'] ?? null,
|
||||
'windshear' => $data['windshear'] ?? null,
|
||||
'electronic_flight' => $data['electronic_flight'] ?? null,
|
||||
'winglets' => $data['winglets'] ?? null,
|
||||
'deskripsi_konfigurasi' => $data['deskripsi_konfigurasi'] ?? null,
|
||||
|
||||
'maksimal_penumpang' => $data['maksimal_penumpang'] ?? null,
|
||||
'jumlah_kursi' => $data['jumlah_kursi'] ?? null,
|
||||
'kursi_pramugari_pramugara' => $data['kursi_pramugari_pramugara'] ?? null,
|
||||
'kartu_fitur_keselamatan' => $data['kartu_fitur_keselamatan'] ?? null,
|
||||
'sabuk_pengaman' => $data['sabuk_pengaman'] ?? null,
|
||||
'lampu_kabin' => $data['lampu_kabin'] ?? null,
|
||||
'lampu_pintu_keluar' => $data['lampu_pintu_keluar'] ?? null,
|
||||
'intercom_kabin' => $data['intercom_kabin'] ?? null,
|
||||
'deskripsi_kabin' => $data['deskripsi_kabin'] ?? null,
|
||||
|
||||
'badan_pesawat' => $data['badan_pesawat'] ?? null,
|
||||
'sayap_pesawat' => $data['sayap_pesawat'] ?? null,
|
||||
'ekor_pesawat' => $data['ekor_pesawat'] ?? null,
|
||||
'landing_gear' => $data['landing_gear'] ?? null,
|
||||
'sistem_pengelasan' => $data['sistem_pengelasan'] ?? null,
|
||||
'deskripsi_struktur' => $data['deskripsi_struktur'] ?? null,
|
||||
|
||||
'gps' => $data['gps'] ?? null,
|
||||
'radar' => $data['radar'] ?? null,
|
||||
'radio_komunikasi' => $data['radio_komunikasi'] ?? null,
|
||||
'lampu_navigasi' => $data['lampu_navigasi'] ?? null,
|
||||
'sistem_autopilot' => $data['sistem_autopilot'] ?? null,
|
||||
'deskripsi_navigasi' => $data['deskripsi_navigasi'] ?? null,
|
||||
|
||||
'tangki_bahan_bakar' => $data['tangki_bahan_bakar'] ?? null,
|
||||
'saluran_pipa_bahan_bakar' => $data['saluran_pipa_bahan_bakar'] ?? null,
|
||||
'pompa_bahan_bakar' => $data['pompa_bahan_bakar'] ?? null,
|
||||
'sistem_hidrolik_utama' => $data['sistem_hidrolik_utama'] ?? null,
|
||||
'sistem_pendigin_hidrolik' => $data['sistem_pendigin_hidrolik'] ?? null,
|
||||
'deskripsi_hidrolik' => $data['deskripsi_hidrolik'] ?? null,
|
||||
|
||||
'mesin_utama' => $data['mesin_utama'] ?? null,
|
||||
'sistem_pendorong' => $data['sistem_pendorong'] ?? null,
|
||||
'sistem_pendigin_mesin' => $data['sistem_pendigin_mesin'] ?? null,
|
||||
'sistem_pelumasan' => $data['sistem_pelumasan'] ?? null,
|
||||
'filter_dan_perangkat_pendukung' => $data['filter_dan_perangkat_pendukung'] ?? null,
|
||||
'deskripsi_kondisi_mesin' => $data['deskripsi_kondisi_mesin'] ?? null,
|
||||
|
||||
'jaket_pelampung' => $data['jaket_pelampung'] ?? null,
|
||||
'pintu_darurat' => $data['pintu_darurat'] ?? null,
|
||||
'alat_pemadaman_kebakaran' => $data['alat_pemadaman_kebakaran'] ?? null,
|
||||
'sistem_alaram_darurat' => $data['sistem_alaram_darurat'] ?? null,
|
||||
'sekoci' => $data['sekoci'] ?? null,
|
||||
'masker_oxigen' => $data['masker_oxigen'] ?? null,
|
||||
'sabuk_pengaman' => $data['sabuk_pengaman'] ?? null,
|
||||
'deskripsi_fungsi_keselamatan' => $data['deskripsi_fungsi_keselamatan'] ?? null,
|
||||
|
||||
'sistem_ventilasi_ac' => $data['sistem_ventilasi_ac'] ?? null,
|
||||
'sistem_penerangan_kabin' => $data['sistem_penerangan_kabin'] ?? null,
|
||||
'panel_informasi_penumpang' => $data['panel_informasi_penumpang'] ?? null,
|
||||
'sistem_hiburan_kabin' => $data['sistem_hiburan_kabin'] ?? null,
|
||||
'deskripsi_Interior' => $data['deskripsi_Interior'] ?? null,
|
||||
|
||||
// Validasi untuk faktor dan kesimpulan
|
||||
'faktor_positif' => $data['faktor_positif'] ?? null,
|
||||
'faktor_negatif' => $data['faktor_negatif'] ?? null,
|
||||
'kesimpulan' => $data['kesimpulan'] ?? null,
|
||||
'catatan' => $data['catatan'] ?? null,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
private function getUnitData($data, $request): array
|
||||
{
|
||||
return [
|
||||
'action' => $data['action'] ?? null,
|
||||
'luas_unit' => $data['luas_unit'] ?? null,
|
||||
'luas_unit_tidak_sesuai' => $data['luas_unit_tidak_sesuai'] ?? null,
|
||||
'jenis_unit' => $data['jenis_unit'] ?? null,
|
||||
'kondisi_unit' => $data['kondisi_unit'] ?? null,
|
||||
'posisi_unit' => $data['posisi_unit'] ?? null,
|
||||
'lantai' => $data['lantai'] ?? null,
|
||||
'view' => $data['view'] ?? null,
|
||||
'bentuk_unit' => $data['bentuk_unit'] ?? null,
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -38,8 +38,8 @@ class FormSurveyorRequest extends FormRequest
|
||||
'kapal' => $this->getKapalRules(),
|
||||
'kendaraan' => $this->getKendaraanRules(),
|
||||
'mesin' => $this->getMesinRules(),
|
||||
'pesawat' => $this->getLinkunganRules(),
|
||||
'alat-berat' => $this->getLinkunganRules(),
|
||||
'pesawat' => $this->getPesawatRules(),
|
||||
'alat-berat' => $this->getAlatBeratRules(),
|
||||
'apartemen-kantor' => $this->getUnitRules(),
|
||||
'lingkungan' => $this->getLinkunganRules(),
|
||||
'fakta' => $this->getCommonRules(),
|
||||
@@ -163,7 +163,7 @@ class FormSurveyorRequest extends FormRequest
|
||||
return [
|
||||
'action' => 'required',
|
||||
'nama_wakil_debitur' => 'required',
|
||||
'hubungan_calon_debitur' => 'required',
|
||||
'hub_calon_debitur' => 'required',
|
||||
'dermaga' => 'required',
|
||||
'desa_kelurahan' => 'required',
|
||||
'kecamatan' => 'required',
|
||||
@@ -173,11 +173,14 @@ class FormSurveyorRequest extends FormRequest
|
||||
'size.*' => 'required',
|
||||
'kondisi.*' => 'required',
|
||||
'klasifikasi.*' => 'required',
|
||||
|
||||
'nama_kapal' => 'required',
|
||||
'pemilik_kapal' => 'required',
|
||||
'bendera' => 'required',
|
||||
'nomor_tanda_selar_kapal' => 'required',
|
||||
'nomor_selar' => 'required',
|
||||
'kapal' => 'required',
|
||||
'galangan_kapal' => 'required',
|
||||
'kapal_shipyard' => 'required',
|
||||
'tahun_pembuatan' => 'required',
|
||||
'tahun_launcing' => 'required',
|
||||
'dwt' => 'required',
|
||||
@@ -190,23 +193,27 @@ class FormSurveyorRequest extends FormRequest
|
||||
'beam' => 'required',
|
||||
'depth' => 'required',
|
||||
'draft' => 'required',
|
||||
|
||||
'lambung_kapal' => 'required',
|
||||
'dek' => 'required',
|
||||
'struktur_kapal' => 'required',
|
||||
'struktur_rangka' => 'required',
|
||||
'palka' => 'required',
|
||||
'pondasi_mesin' => 'required',
|
||||
'area_mesin' => 'required',
|
||||
'cat_korosi' => 'required',
|
||||
'cat_dan_korosi' => 'required',
|
||||
'sistem_pengelasan' => 'required',
|
||||
'deskripsi_lain' => 'required',
|
||||
'deskripsi_struktur' => 'required',
|
||||
|
||||
'sekoci' => 'required',
|
||||
'jaket_pelampung' => 'required',
|
||||
'alat_pemadaman' => 'required',
|
||||
'rambu_darurat' => 'required',
|
||||
'sistem_pencegahan' => 'required',
|
||||
'sistem_alarm' => 'required',
|
||||
'sistem_pencegah' => 'required',
|
||||
'kebakaran' => 'required',
|
||||
'lampu_darurat' => 'required',
|
||||
'deskripsi_peralatan' => 'required',
|
||||
|
||||
'gps' => 'required',
|
||||
'radar' => 'required',
|
||||
'radio_komunikasi' => 'required',
|
||||
@@ -214,6 +221,7 @@ class FormSurveyorRequest extends FormRequest
|
||||
'sistem_kendali_otomatis' => 'required',
|
||||
'kompas' => 'required',
|
||||
'deskripsi_navigasi' => 'required',
|
||||
|
||||
'mesin_utama' => 'required',
|
||||
'mesin_bantu' => 'required',
|
||||
'pompa_pendingin' => 'required',
|
||||
@@ -221,15 +229,24 @@ class FormSurveyorRequest extends FormRequest
|
||||
'propeller' => 'required',
|
||||
'sistem_kelistrikan' => 'required',
|
||||
'deskripsi_mesin_penggerak' => 'required',
|
||||
|
||||
'lampu_navigasi' => 'required',
|
||||
'sistem_penerangan' => 'required',
|
||||
'sistem_panel_distribusi' => 'required',
|
||||
'kabel_perangkat' => 'required',
|
||||
'deskripsi_kelistrikan' => 'required',
|
||||
|
||||
'kebersihan_dek_luar' => 'required',
|
||||
'tangki_limbah' => 'required',
|
||||
'sistem_pengelolaan_limbah' => 'required',
|
||||
'pengelolaan_air_ballast' => 'required',
|
||||
'pengelolaan_air_ballast' => 'required',
|
||||
'deskripsi_kebersihan' => 'required',
|
||||
|
||||
'fakta_positif.*' => 'nullable',
|
||||
'fakta_negatif.*' => 'nullable',
|
||||
'analisa_makro.*' => 'nullable',
|
||||
'kesimpulan.*' => 'nullable',
|
||||
'catatan.*' => 'nullable',
|
||||
];
|
||||
}
|
||||
|
||||
@@ -237,8 +254,56 @@ class FormSurveyorRequest extends FormRequest
|
||||
{
|
||||
return [
|
||||
'action' => 'required',
|
||||
'kondisi_kendaraan' => 'required',
|
||||
'kondisi_kendaraan_lain' => 'required',
|
||||
'tanggal_survey' => 'required',
|
||||
'nama_wakil' => 'required',
|
||||
'hub_calon_debitur' => 'required',
|
||||
'nama_jalan' => 'required',
|
||||
'perumahan_gang' => 'required',
|
||||
'blok_nomor' => 'required',
|
||||
'desa_kelurahan' => 'required',
|
||||
'kecamatan' => 'required',
|
||||
'kota_madya' => 'required',
|
||||
'provinsi' => 'required',
|
||||
'kondisi' => 'required',
|
||||
'nomor_polisi' => 'required',
|
||||
'nomor_polis_tidak_sesuai' => 'nullable',
|
||||
'merek' => 'required',
|
||||
'merek_tidak_sesuai' => 'nullable',
|
||||
'warna' => 'required',
|
||||
'warna_tidak_sesuai' => 'nullable',
|
||||
'nomor_rangka' => 'required',
|
||||
'nomor_rangka_tidak_sesuai' => 'nullable',
|
||||
'nomor_mesin' => 'required',
|
||||
'nomor_mesin_tidak_sesuai' => 'nullable',
|
||||
'posisi_kilometer' => 'required',
|
||||
'transmisi' => 'required',
|
||||
'mesin_panel_instrument.*' => 'required',
|
||||
'fungsi_mesin_panel_instrument.*' => 'required',
|
||||
'interior.*' => 'required',
|
||||
'jumlah_pintu.*' => 'required',
|
||||
'rangka_karoseri.*' => 'required',
|
||||
'ban.*' => 'required',
|
||||
'velg.*' => 'required',
|
||||
'bamper_depan.*' => 'required',
|
||||
'bamper_belakang.*' => 'required',
|
||||
'lampu_depan.*' => 'required',
|
||||
'lampu_belakang.*' => 'required',
|
||||
'kaca_kendaraan.*' => 'required',
|
||||
'air_conditioner.*' => 'required',
|
||||
'tape_radio_cd.*' => 'required',
|
||||
'sensor_parkir.*' => 'required',
|
||||
'sensor_camera_recorder.*' => 'required',
|
||||
'lcd.*' => 'required',
|
||||
'sabuk_keselamatan.*' => 'required',
|
||||
'airbag.*' => 'required',
|
||||
'asuransi.*' => 'required',
|
||||
'perusahaan_asuransi' => 'required',
|
||||
'tahun_berakhir' => 'required',
|
||||
'fakta_positif.*' => 'nullable',
|
||||
'fakta_negatif.*' => 'nullable',
|
||||
'analisa_makro.*' => 'nullable',
|
||||
'kesimpulan.*' => 'nullable',
|
||||
'catatan.*' => 'nullable',
|
||||
];
|
||||
}
|
||||
|
||||
@@ -247,8 +312,24 @@ class FormSurveyorRequest extends FormRequest
|
||||
{
|
||||
return [
|
||||
'action' => 'required',
|
||||
'kondisi_mesin' => 'required',
|
||||
'kondisi_mesin_lain' => 'required',
|
||||
'nama_wakil' => 'required',
|
||||
'nama_jalan' => 'required',
|
||||
'perumahan_gang' => 'required',
|
||||
'blok' => 'required',
|
||||
'desa_kelurahan' => 'required',
|
||||
'kecamatan' => 'required',
|
||||
'kota_madya' => 'required',
|
||||
'provinsi' => 'required',
|
||||
'hub_calon_debitur' => 'required',
|
||||
'tipe_model' => 'required',
|
||||
'merek' => 'required',
|
||||
'tahun_pembuatan' => 'required',
|
||||
'negara_pembuat' => 'required',
|
||||
'kondisi_mesin' => 'required',
|
||||
'faktor_positif' => 'nullable',
|
||||
'faktor_negatif' => 'nullable',
|
||||
'kesimpulan' => 'nullable',
|
||||
'catatan' => 'nullable',
|
||||
];
|
||||
}
|
||||
|
||||
@@ -258,60 +339,172 @@ class FormSurveyorRequest extends FormRequest
|
||||
return [
|
||||
'action' => 'required',
|
||||
'tanggal_survey' => 'required',
|
||||
'nama_wakili' => 'required',
|
||||
'nama_wakil' => 'required',
|
||||
'hub_calon_debitur' => 'required',
|
||||
'dengan_wadeb' => 'required',
|
||||
'nama_jalan' => 'required',
|
||||
'perumahan_gang'=>'required',
|
||||
'perumahan_gang' => 'required',
|
||||
'blok' => 'required',
|
||||
'desa_kelurahan' => 'required',
|
||||
'kecamatan' => 'required',
|
||||
'kota_madya' => 'required',
|
||||
'provinsi' => 'required',
|
||||
'masa_berlaku_stnk' => 'required',
|
||||
'masa_berlaku_pajak' => 'required',
|
||||
'kendaraan' => 'required',
|
||||
'jenis_model' => 'required',
|
||||
'nomor_lambung' => 'required',
|
||||
'model_unit' => 'required',
|
||||
'tahun_pembuatan' => 'required',
|
||||
'merk' => 'required',
|
||||
'detail_merek' => 'required',
|
||||
'kondisi' => 'required',
|
||||
'nomor_polisi' => 'nullable',
|
||||
'merek' => 'nullable',
|
||||
'warna' => 'nullable',
|
||||
'nomor_rangka'=>'nullable',
|
||||
'nomor_mesin'=>'nullable',
|
||||
'posisi_kilometer' => 'nullable',
|
||||
'transmisi' => 'nullable',
|
||||
'mesin_instrument' => 'nullable',
|
||||
'fungsi_instrument' => 'nullable',
|
||||
'interior' => 'nullable',
|
||||
'jumlah' => 'nullable',
|
||||
'rangka' => 'nullable',
|
||||
'ban' => 'nullable',
|
||||
'velg' => 'nullable',
|
||||
'bamper_depan' => 'nullable',
|
||||
'bamper_belakang' => 'nullable',
|
||||
'lampu_depan' => 'nullable',
|
||||
'lampu_belakang' => 'nullable',
|
||||
'kaca' => 'nullable',
|
||||
'air_conditions' => 'nullable',
|
||||
'tape_radio' => 'nullable',
|
||||
'sensor_parkir' => 'nullable',
|
||||
'sensor_kamera' => 'nullable',
|
||||
'lcd' => 'nullable',
|
||||
'sabuk_keselamatan' => 'nullable',
|
||||
'air_bag' => 'nullable',
|
||||
'asuransi' => 'nullable',
|
||||
'negara_pembuat' => 'required',
|
||||
'tahun_pembelian' => 'required',
|
||||
'nomor_faktur' => 'nullable',
|
||||
'nomor_kontrak' => 'nullable',
|
||||
'nama_pemilik' => 'nullable',
|
||||
'alamat_pemilik' => 'nullable',
|
||||
'nomor_asuransi' => 'nullable',
|
||||
'nomor_rangka' => 'nullable',
|
||||
'nomor_mesin' => 'nullable',
|
||||
'hour_mesters' => 'nullable',
|
||||
'overhaul_mesin' => 'nullable',
|
||||
'mesin_panel.*' => 'nullable',
|
||||
'fungsi_panel.*' => 'nullable',
|
||||
'interior.*' => 'nullable',
|
||||
'rangka_Karoseri.*' => 'nullable',
|
||||
'ban.*' => 'nullable',
|
||||
'velg.*' => 'nullable',
|
||||
'air_conditioner.*' => 'nullable',
|
||||
'aksesoris.*' => 'nullable',
|
||||
'lcd.*' => 'nullable',
|
||||
'perlengkapan.*' => 'nullable',
|
||||
'asuransi.*' => 'nullable',
|
||||
'perusahaan_asuransi.*' => 'nullable',
|
||||
'tahun_berakhir.*' => 'nullable',
|
||||
'sensor_kamera.*' => 'nullable',
|
||||
'lcd.*' => 'nullable',
|
||||
'sabuk_keselamatan.*' => 'nullable',
|
||||
'air_bag.*' => 'nullable',
|
||||
'asuransi.*' => 'nullable',
|
||||
'perusahan_asuransi' => 'nullable',
|
||||
'tahun_berakhir' => 'nullable',
|
||||
'faktor_positif' => 'nullable',
|
||||
'faktor_negatif' => 'nullable',
|
||||
'analisa_makro' => 'nullable',
|
||||
'kesimpulan' => 'nullable',
|
||||
'catatan_lainnya' => 'nullable',
|
||||
'catatan' => 'nullable',
|
||||
];
|
||||
}
|
||||
|
||||
|
||||
|
||||
private function getPesawatRules(): array
|
||||
{
|
||||
return [
|
||||
'action' => 'required',
|
||||
'tanggal_survey' => 'required',
|
||||
'nama_wakil' => 'required',
|
||||
'hub_calon_debitur' => 'required',
|
||||
'bandara' => 'required',
|
||||
'desa_kelurahan' => 'required',
|
||||
'kecamatan' => 'required',
|
||||
'kota_madya' => 'required',
|
||||
'provinsi' => 'required',
|
||||
|
||||
'jenis_pesawat' => 'required',
|
||||
'size' => 'required',
|
||||
'kondisi' => 'required',
|
||||
'nama_pesawat' => 'required',
|
||||
'model' => 'required',
|
||||
'nomor_registrasi' => 'required',
|
||||
'tahun_pembuatan' => 'required',
|
||||
'certificate_of_airworthines' => 'required',
|
||||
'certificate_of_registration' => 'required',
|
||||
'total_service_hours' => 'required',
|
||||
'total_service_cycles' => 'required',
|
||||
|
||||
'last_a_check' => 'required',
|
||||
'next_a_check' => 'required',
|
||||
'last_b_check' => 'required',
|
||||
'next_b_check' => 'required',
|
||||
'last_c_check' => 'required',
|
||||
'next_c_check' => 'required',
|
||||
'next_d_check' => 'required',
|
||||
'last_d_check' => 'required',
|
||||
'deskripsi_maintenence' => 'nullable',
|
||||
|
||||
'instrument_landing_system' => 'required',
|
||||
'traffic_collision_avoidance_system' => 'required',
|
||||
'windshear' => 'required',
|
||||
'electronic_flight' => 'required',
|
||||
'winglets' => 'required',
|
||||
'deskripsi_konfigurasi' => 'required',
|
||||
|
||||
|
||||
'maksimal_penumpang' => 'required',
|
||||
'jumlah_kursi' => 'required',
|
||||
'kursi_pramugari_pramugara' => 'required',
|
||||
'kartu_fitur_keselamatan' => 'required',
|
||||
'sabuk_pengaman' => 'required',
|
||||
'lampu_kabin' => 'required',
|
||||
'lampu_pintu_keluar' => 'required',
|
||||
'intercom_kabin' => 'required',
|
||||
'deskripsi_kabin' => 'required',
|
||||
|
||||
|
||||
'badan_pesawat' => 'required',
|
||||
'sayap_pesawat' => 'required',
|
||||
'ekor_pesawat' => 'required',
|
||||
'landing_gear' => 'required',
|
||||
'sabuk_pengaman' => 'required',
|
||||
'sistem_pengelasan' => 'required',
|
||||
'deskripsi_struktur' => 'required',
|
||||
|
||||
'gps' => 'required',
|
||||
'radar' => 'required',
|
||||
'radio_komunikasi' => 'required',
|
||||
'lampu_navigasi' => 'required',
|
||||
'sistem_autopilot' => 'required',
|
||||
'deskripsi_navigasi' => 'required',
|
||||
|
||||
'tangki_bahan_bakar' => 'required',
|
||||
'saluran_pipa_bahan_bakar' => 'required',
|
||||
'pompa_bahan_bakar' => 'required',
|
||||
'sistem_hidrolik_utama' => 'required',
|
||||
'sistem_pendigin_hidrolik' => 'required',
|
||||
'deskripsi_hidrolik' => 'required',
|
||||
|
||||
'mesin_utama' => 'required',
|
||||
'sistem_pendorong' => 'required',
|
||||
'sistem_pendigin_mesin' => 'required',
|
||||
'sistem_pelumasan' => 'required',
|
||||
'filter_dan_perangkat_pendukung' => 'required',
|
||||
'deskripsi_kondisi_mesin' => 'required',
|
||||
|
||||
|
||||
'jaket_pelampung' => 'required',
|
||||
'pintu_darurat' => 'required',
|
||||
'alat_pemadaman_kebakaran' => 'required',
|
||||
'sistem_alaram_darurat' => 'required',
|
||||
'sekoci' => 'required',
|
||||
'masker_oxigen' => 'required',
|
||||
'sabuk_pengaman' => 'required',
|
||||
'deskripsi_fungsi_keselamatan' => 'required',
|
||||
|
||||
|
||||
'sistem_ventilasi_ac' => 'required',
|
||||
'sistem_penerangan_kabin' => 'required',
|
||||
'panel_informasi_penumpang' => 'required',
|
||||
'sistem_hiburan_kabin' => 'required',
|
||||
'deskripsi_Interior' => 'required',
|
||||
|
||||
|
||||
|
||||
'faktor_positif.*' => 'nullable',
|
||||
'faktor_negatif.*' => 'nullable',
|
||||
'kesimpulan.*' => 'nullable',
|
||||
'catatan.*' => 'nullable',
|
||||
|
||||
|
||||
];
|
||||
}
|
||||
|
||||
private function getAssetDescriptionRules(): array
|
||||
{
|
||||
return [
|
||||
|
||||
@@ -75,7 +75,7 @@
|
||||
name="form_kategori[]" multiple="multiple">
|
||||
|
||||
<option value="">Pilih Form</option>
|
||||
@foreach (['tanah', 'bangunan', 'kapal', 'kendaraan', 'mesin', 'pesawat', 'alat-berat', 'apartemen-kantor','lingkungan', 'fakta'] as $item)
|
||||
@foreach (['tanah', 'bangunan', 'kapal', 'kendaraan', 'mesin', 'pesawat', 'alat-berat', 'apartemen-kantor','lingkungan', 'fakta','informasi'] as $item)
|
||||
<option value="{{ $item }}"
|
||||
@if (isset($jenisJaminan->form_kategori) && in_array($item, json_decode($jenisJaminan->form_kategori, true))) {{ 'selected' }} @endif>
|
||||
{{ $item }}
|
||||
|
||||
@@ -368,7 +368,7 @@
|
||||
<div class="modal-footer justify-end mt-2">
|
||||
<div class="flex gap-4">
|
||||
<button type="button" class="btn btn-light" data-modal-dismiss="true">Cancel</button>
|
||||
<button id="btnSubmit" type="submit" class="btn btn-primary">Submit</button>
|
||||
<button id="btnSubmit" type="submit" class="btn btn-primary" data-modal-dismiss="true">Submit</button>
|
||||
</div>
|
||||
</div>
|
||||
</form>
|
||||
|
||||
@@ -1,159 +1,425 @@
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Order Penilaian</h1>
|
||||
</div>
|
||||
|
||||
<div class="grid gap-5 grid-cols-2">
|
||||
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Identitas Debitur</h1>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tujuan Penilaian</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->tujuanPenilaian))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->tujuanPenilaian->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tanggal Survey</label>
|
||||
<div class="flex flex-wrap items-base line w-full">
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->created_at->format('d/m/Y') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Cab/Direktorat</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->branch))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->branch->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">AO</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->user))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->user->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- lokasi jaminan --}}
|
||||
@include('lpj::surveyor.components.lokasi-jaminan')
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Data Data Jaminan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Model</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select class="input tomselect w-full @error('hadapMataAngin') border-danger bg-danger-light @enderror"
|
||||
name="hadapMataAngin">
|
||||
<option value="">Select Model Kendaraan </option>
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->name }}"
|
||||
{{ old('hadapMataAngin') == $item->name ? 'selected' : '' }}>{{ $item->name }}
|
||||
</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Identitas Debitur</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->debiture->name))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->debiture->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Wakil Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="nama_wakil" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
<em id="error-nama_wakil" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="hub_calon_debitur" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
<em id="error-hub_calon_debitur" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$inputDataJaminan = [];
|
||||
{{-- lokasi jaminan --}}
|
||||
@include('lpj::surveyor.components.lokasi-jaminan')
|
||||
</div>
|
||||
</div>
|
||||
|
||||
$inputDataJaminan = [
|
||||
['label' => 'Nomor Lambung', 'index' => 0],
|
||||
['label' => 'Model Unit', 'index' => 1],
|
||||
['label' => 'Tahun Pembuatan', 'index' => 2],
|
||||
['label' => 'Merk', 'index' => 3],
|
||||
['label' => 'Negara Pembuat', 'index' => 4],
|
||||
['label' => 'Tahun Pembelian', 'index' => 5],
|
||||
['label' => 'Nomor Faktur/Invoice', 'index' => 6],
|
||||
['label' => 'Nomor Kontrak Pembelian', 'index' => 7],
|
||||
['label' => 'Nama Pemilik', 'index' => 8],
|
||||
['label' => 'Alamaat Pemilik', 'index' => 9],
|
||||
['label' => 'Nomor Asuransi', 'index' => 10],
|
||||
['label' => 'Nomor Rangka', 'index' => 11],
|
||||
['label' => 'Nomor Mesin', 'index' => 12],
|
||||
['label' => 'Hour Mesin', 'index' => 13],
|
||||
['label' => 'Overhaul Mesin', 'index' => 14],
|
||||
];
|
||||
|
||||
@endphp
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Data Data Jaminan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Model</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('model_unit') border-danger bg-danger-light @enderror"
|
||||
name="jenis_model">
|
||||
<option value="">Select Model Kendaraan </option>
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->name }}"
|
||||
{{ old('') == $item->name ? 'selected' : '' }}>{{ $item->name }}
|
||||
</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@if (count($inputDataJaminan) > 0)
|
||||
@foreach ($inputDataJaminan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
<em id="error-jenis_model" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
|
||||
@php
|
||||
|
||||
$inputDataJaminan = [
|
||||
[
|
||||
'label' => 'Nomor Lambung',
|
||||
'name' => 'nomor_lambung',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Model Unit',
|
||||
'name' => 'model_unit',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Tahun Pembuatan',
|
||||
'name' => 'tahun_pembuatan',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Merk',
|
||||
'name' => 'merk',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Negara Pembuat',
|
||||
'name' => 'negara_pembuat',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Tahun Pembelian',
|
||||
'name' => 'tahun_pembelian',
|
||||
'index' => 5,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Faktur/Invoice',
|
||||
'name' => 'nomor_faktur',
|
||||
'index' => 6,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Kontrak Pembelian',
|
||||
'name' => 'nomor_kontrak',
|
||||
'index' => 7,
|
||||
],
|
||||
[
|
||||
'label' => 'Nama Pemilik',
|
||||
'name' => 'nama_pemilik',
|
||||
'index' => 8,
|
||||
],
|
||||
[
|
||||
'label' => 'Alamaat Pemilik',
|
||||
'name' => 'alamat_pemilik',
|
||||
'index' => 9,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Asuransi',
|
||||
'name' => 'nomor_asuransi',
|
||||
'index' => 10,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Rangka',
|
||||
'name' => 'nomor_rangka',
|
||||
'index' => 11,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Mesin',
|
||||
'name' => 'nomor_mesin',
|
||||
'index' => 12,
|
||||
],
|
||||
[
|
||||
'label' => 'Hour Meters',
|
||||
'name' => 'hour_mesters',
|
||||
'index' => 13,
|
||||
],
|
||||
[
|
||||
'label' => 'Overhaul Mesin',
|
||||
'name' => 'overhaul_mesin',
|
||||
'index' => 14,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataJaminan) > 0)
|
||||
@foreach ($inputDataJaminan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
|
||||
<em id="error-{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Kondisi Objek Jaminan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Model</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select class="input tomselect w-full @error('hadapMataAngin') border-danger bg-danger-light @enderror"
|
||||
name="hadapMataAngin">
|
||||
<option value="">Select Model Kendaraan </option>
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->name }}"
|
||||
{{ old('hadapMataAngin') == $item->name ? 'selected' : '' }}>{{ $item->name }}
|
||||
</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Kondisi Objek Jaminan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
$kondisiObjeck = [
|
||||
[
|
||||
'label' => 'Mesin dan Panel Instrument',
|
||||
'value' => ['Terawat', 'Cukup Terawat', 'Tidak Terawat'],
|
||||
'name' => 'mesin_panel',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Fungsi mesin dan panel instrument',
|
||||
'value' => ['Berfungsi', 'Rusak'],
|
||||
'name' => 'fungsi_panel',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Interior (jok, dll)',
|
||||
'value' => ['Terawat', 'Cukup Terawat', 'Tidak Terawat'],
|
||||
'name' => 'interior',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Rangka dan Karoseri',
|
||||
'value' => ['Terawat', 'Cukup Terawat', 'Tidak Terawat'],
|
||||
'name' => 'rangka_Karoseri',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Ban',
|
||||
'value' => ['Standard', 'Tidak Standard'],
|
||||
'name' => 'ban',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Velg',
|
||||
'value' => ['Standard', 'Tidak Standard'],
|
||||
'name' => 'velg',
|
||||
'index' => 5,
|
||||
],
|
||||
[
|
||||
'label' => 'Air Conditioner',
|
||||
'value' => ['Ada', 'Tidak Ada'],
|
||||
'name' => 'air_conditioner',
|
||||
'index' => 6,
|
||||
],
|
||||
[
|
||||
'label' => 'Aksesoris Tambahan lainnya',
|
||||
'value' => ['Ada', 'Tidak Ada'],
|
||||
'name' => 'aksesoris',
|
||||
'index' => 7,
|
||||
],
|
||||
[
|
||||
'label' => 'LCD',
|
||||
'value' => ['Ada', 'Tidak Ada'],
|
||||
'name' => 'lcd',
|
||||
'index' => 8,
|
||||
],
|
||||
[
|
||||
'label' => 'Perlengkapan Keamanan',
|
||||
'value' => ['Ada', 'Tidak Ada'],
|
||||
'name' => 'perlengkapan',
|
||||
'index' => 9,
|
||||
],
|
||||
[
|
||||
'label' => 'Asuransi',
|
||||
'value' => ['Ada', 'Tidak Ada'],
|
||||
'name' => 'asuransi',
|
||||
'index' => 10,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($kondisiObjeck) > 0)
|
||||
@foreach ($kondisiObjeck as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="flex flex-col items-start gap-4">
|
||||
@if (isset($item['value']))
|
||||
@foreach ($item['value'] as $value)
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56 gap-2.5" style="width: 500px">
|
||||
<input class="checkbox" name="{{ $item['name'] }}[]" type="checkbox"
|
||||
value="{{ $value }}"
|
||||
{{ in_array($value, old($item['name'], $forminspeksi[$item['name']] ?? [])) ? 'checked' : '' }} />
|
||||
{{ $value }}
|
||||
</label>
|
||||
<input type="text" name="{{ $item['name'] }}_input[]"
|
||||
class="input w-full"
|
||||
id="bentukTanahInput-{{ $loop->parent->index }}-{{ $loop->index }}"
|
||||
placeholder="Masukkan {{ $value }}..."
|
||||
value="{{ old($item['name'] . '_input.' . $loop->index, $forminspeksi[$item['name'] . '_input'][$loop->index] ?? '') }}">
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
<div class="w-full">
|
||||
<em id="error-{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
<em id="error-{{ $item['name'] }}-input-{{ $loop->index }}"
|
||||
class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Perusahaan Asuransi</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="perusahaan_asuransi" class="input"
|
||||
placeholder="Pesurahaan Asuransi">
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tahun Berakhir</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="date" name="tahun_berakhir" class="input" placeholder="Tahun berakhir">
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$kondisiObjeck = [];
|
||||
|
||||
$kondisiObjeck = [
|
||||
['label' => 'Mesin dan Panel Instrument', 'index' => 0],
|
||||
['label' => 'Fungsi mesin dan panel instrument', 'index' => 1],
|
||||
['label' => 'Interior (jok, dll)', 'index' => 2],
|
||||
['label' => 'Rangka dan Karoseri', 'index' => 3],
|
||||
['label' => 'Ban', 'index' => 4],
|
||||
['label' => 'Velg', 'index' => 5],
|
||||
['label' => 'Air Conditioner', 'index' => 6],
|
||||
['label' => 'Aksesoris Tambahan lainnya', 'index' => 7],
|
||||
['label' => 'LCD', 'index' => 8],
|
||||
['label' => 'Perlengkapan Keamanan', 'index' => 9],
|
||||
['label' => 'Asuransi', 'index' => 10],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($kondisiObjeck) > 0)
|
||||
@foreach ($kondisiObjeck as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card bg-white rounded-lg overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class=" py-4 ">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisis Fakta</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Positif</label>
|
||||
<div id="fakta-positif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_positif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_positif[]" rows="3">{{ old('fakta_positif.0', $forminspeksi['fakta_positif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_positif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-positif-container', 'fakta_positif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Negatif</label>
|
||||
<div id="fakta-negatif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_negatif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_negatif[]" rows="3">{{ old('fakta_negatif.0', $forminspeksi['fakta_negatif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_negatif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-negatif-container', 'fakta_negatif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Catatan Yang Perlu Diperhatikan</label>
|
||||
<div id="catatan-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="catatan flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="catatan[]" rows="3">{{ old('catatan.0', $forminspeksi['catatan'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-catatan" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button"
|
||||
onclick="addClonableItem('catatan-container', 'catatan')"
|
||||
class="btn btn-primary btn-sm mt-5 ">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -116,8 +116,6 @@
|
||||
</div>
|
||||
<!-- Spek Bangunan -->
|
||||
|
||||
|
||||
|
||||
<div class="gap-2.5">
|
||||
<div class="flex items-stretch flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Spek Bangunan</label>
|
||||
@@ -145,7 +143,6 @@
|
||||
@endif
|
||||
@endforeach
|
||||
</div>
|
||||
|
||||
<em id="error-spek_bangunan_{{ $item->name }}"
|
||||
class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
@@ -154,13 +151,13 @@
|
||||
@endif
|
||||
</div>
|
||||
<button type="button"
|
||||
class="mt-2 btn btn-danger btn-outline btn-xs delete-button">Hapus</button>
|
||||
class="mt-2 btn btn-danger btn-outline btn-xs remove-btn" style="display: none;">Hapus</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex justify-end">
|
||||
<button class="btn btn-xs btn-primary" type="button" id="addBagunan">
|
||||
<button class="btn btn-xs btn-primary" type="button" onclick="addClonableItem('spek-bangunan-container', 'spek-bangunan')">
|
||||
tambah bangunan
|
||||
<i class="ki-filled ki-plus"></i>
|
||||
</button>
|
||||
|
||||
@@ -6,9 +6,13 @@
|
||||
@elseif(request()->has('form') && request('form') === 'foto')
|
||||
<a class="card border-2 border-dashed border-brand-clarity bg-center bg-[length:600px] bg-no-repeat add-new-bg"
|
||||
href="{{ route('surveyor.foto', ['id' => $permohonan->id, 'jaminanId' => $dokumen->jenisJaminan->id]) }}?form=create-foto&foto={{ $permohonan->id }}&jenis_jaminan={{ $dokumen->jenisJaminan->id }}">
|
||||
@elseif(request()->has('form') && request('form') === 'inspeksi')
|
||||
@elseif(request()->has('form') && request('form') === 'inspeksi')
|
||||
<a class="card border-2 border-dashed border-brand-clarity bg-center bg-[length:600px] bg-no-repeat add-new-bg"
|
||||
href="{{ route('surveyor.inspeksi', ['id' => $permohonan->id, 'jaminanId' => $dokumen->jenisJaminan->id]) }}?form=create-inspeksi&inspeksi={{ $permohonan->id }}&jenis_jaminan={{ $dokumen->jenisJaminan->id }}">
|
||||
|
||||
@elseif(request()->has('form') && request('form') === 'data-pembanding')
|
||||
<a class="card border-2 border-dashed border-brand-clarity bg-center bg-[length:600px] bg-no-repeat add-new-bg"
|
||||
href="{{ route('surveyor.data-pembanding', ['id' => $permohonan->id, 'jaminanId' => $dokumen->jenisJaminan->id]) }}?form=data-pembanding&pembanding={{ $permohonan->id }}&jenis_jaminan={{ $dokumen->jenisJaminan->id }}">
|
||||
@endif
|
||||
|
||||
<div class="card-body grid items-center">
|
||||
|
||||
@@ -1,30 +1,230 @@
|
||||
@extends('layouts.main')
|
||||
|
||||
<div class="grid">
|
||||
<div class="card-grid min-w-full" data-datatable="false" data-datatable-page-size="5" data-datatable-state-save="false" id="data-table" data-api-url="">
|
||||
<div class="card-header py-5 flex-wrap">
|
||||
{{-- @section('breadcrumbs')
|
||||
{{ Breadcrumbs::render(request()->route()->getName()) }}
|
||||
@endsection --}}
|
||||
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table class="table table-auto table-border align-middle text-gray-700 font-medium text-sm" data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
|
||||
<th class="min-w-[250px]" data-datatable-column="code">
|
||||
<span class="sort"> <span class="sort-label"> Nama </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[250px]" data-datatable-column="name">
|
||||
<span class="sort"> <span class="sort-label"> Data Pembanding </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[50px] text-center" data-datatable-column="actions">Data Pembading 2</th>
|
||||
</tr>
|
||||
</thead>
|
||||
</table>
|
||||
@section('content')
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
<div class="card min-w-full">
|
||||
<div class="card min-w-full">
|
||||
<div class="card-header">
|
||||
<h3 class="card-title">
|
||||
Form Inspeksi
|
||||
</h3>
|
||||
<div class="flex items-center gap-2">
|
||||
<a href="{{ route('surveyor.show', ['id' => request('pembanding')]) }}?form=data-pembanding"
|
||||
class="btn btn-xs btn-info">
|
||||
<i class="ki-filled ki-exit-left"></i> Back
|
||||
</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="grid gap-5">
|
||||
<div class="card-grid min-w-full" data-datatable="false" data-datatable-page-size="5"
|
||||
data-datatable-state-save="false" id="data-table" data-api-url="">
|
||||
<div class="card">
|
||||
<div class="card-header py-5 flex-wrap flex justify-end">
|
||||
<button id="addColumnBtn" class="btn btn-primary btn-sm">
|
||||
<i class="ki-filled ki-plus"></i> Tambah Kolom
|
||||
</button>
|
||||
<button id="removeColumnBtn" class="btn btn-danger btn-sm ml-2" style="display: none;">
|
||||
<i class="ki-filled ki-minus"></i> Hapus Kolom
|
||||
</button>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table id="dataTable"
|
||||
class="table table-auto table-border align-middle text-gray-700 font-medium text-sm"
|
||||
data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="min-w-[250px]" data-datatable-column="code" style="min-width: 350px">
|
||||
<span class="sort"> <span class="sort-label"> Nama </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[250px]" data-datatable-column="name" style="min-width: 350px">
|
||||
<span class="sort"> <span class="sort-label"> Objek Penilaian </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[50px]" data-datatable-column="actions"
|
||||
style="min-width: 350px"id="dataPembanding2Header">
|
||||
Data Pembanding 1
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
<tr>
|
||||
<td>
|
||||
Foto
|
||||
</td>
|
||||
<td>
|
||||
<img src="" class="img-responsive" alt="Gambar Pendamping" style="width: 10rem; height: 10rem; display: none;" id="uploadedImage1">
|
||||
<input type="file" class="file-input" placeholder="" onchange="previewImage(event, 'uploadedImage1')" />
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<img src="" class="img-responsive" alt="Gambar Pendamping" style="width: 10rem; height: 10rem; display: none;" id="uploadedImage2">
|
||||
<input type="file" class="file-input" placeholder="" onchange="previewImage(event, 'uploadedImage2')" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Alamat
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" class="input" placeholder="Objek Penilaian" />
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<input type="text" class="input" placeholder="Data Pembanding 1" />
|
||||
</td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td>
|
||||
Tahun Penilaian
|
||||
</td>
|
||||
<td>
|
||||
<input type="text" class="input" placeholder="Objek Penilaian" />
|
||||
</td>
|
||||
<td class="text-center">
|
||||
<input type="text" class="input" placeholder="Data Pembanding 1" />
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="card-grid min-w-full" data-datatable="false" data-datatable-page-size="5"
|
||||
data-datatable-state-save="false" id="data-table" data-api-url="">
|
||||
<div class="card">
|
||||
<div class="card-header py-5 flex-wrap ">
|
||||
<h1>Informasi khusus</h1>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<div class="scrollable-x-auto">
|
||||
<table id="dataTable"
|
||||
class="table table-auto table-border align-middle text-gray-700 font-medium text-sm"
|
||||
data-datatable-table="true">
|
||||
<thead>
|
||||
<tr>
|
||||
<th class="min-w-[250px]" data-datatable-column="code" style="min-width: 350px">
|
||||
<span class="sort"> <span class="sort-label"> Nama </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[250px]" data-datatable-column="name" style="min-width: 350px">
|
||||
<span class="sort"> <span class="sort-label"> Objek Penilaian </span>
|
||||
<span class="sort-icon"> </span> </span>
|
||||
</th>
|
||||
<th class="min-w-[50px]" data-datatable-column="actions"
|
||||
style="min-width: 350px"id="dataPembanding2Header">
|
||||
Data Pembanding 1
|
||||
</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
|
||||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<script>
|
||||
let columnCount = 1;
|
||||
|
||||
document.getElementById('addColumnBtn').addEventListener('click', function() {
|
||||
columnCount++;
|
||||
const newHeader = document.createElement('th');
|
||||
newHeader.className = 'min-w-[350px] text-center';
|
||||
newHeader.style = 'min-width: 350px';
|
||||
newHeader.innerHTML = `Data Pembanding ${columnCount}`;
|
||||
document.querySelector('#dataTable thead tr').appendChild(newHeader);
|
||||
|
||||
// Tampilkan tombol hapus kolom
|
||||
document.getElementById('removeColumnBtn').style.display = 'inline-block';
|
||||
|
||||
// Tambahkan sel baru ke setiap baris di tbody
|
||||
const rows = document.querySelectorAll('#dataTable tbody tr');
|
||||
rows.forEach((row, index) => {
|
||||
const newCell = document.createElement('td');
|
||||
newCell.className = 'text-center';
|
||||
|
||||
// Hanya baris pertama yang memiliki input file
|
||||
if (index === 0) {
|
||||
// Buat elemen gambar dan input file untuk baris pertama
|
||||
const imgElement = document.createElement('img');
|
||||
imgElement.src = '';
|
||||
imgElement.className = 'img-responsive';
|
||||
imgElement.alt = 'Gambar Pendamping';
|
||||
imgElement.style.width = '10rem';
|
||||
imgElement.style.height = '10rem';
|
||||
imgElement.style.display = 'none';
|
||||
imgElement.id = `uploadedImage${columnCount}-${index + 1}`; // ID unik untuk setiap gambar
|
||||
|
||||
const fileInput = document.createElement('input');
|
||||
fileInput.type = 'file';
|
||||
fileInput.className = 'file-input';
|
||||
fileInput.placeholder = '';
|
||||
fileInput.onchange = function(event) {
|
||||
previewImage(event, imgElement.id);
|
||||
};
|
||||
|
||||
// Tambahkan elemen gambar dan input file ke sel baru
|
||||
newCell.appendChild(imgElement);
|
||||
newCell.appendChild(fileInput);
|
||||
} else {
|
||||
// Untuk baris lainnya, hanya tambahkan input teks
|
||||
const textInput = document.createElement('input');
|
||||
textInput.type = 'text';
|
||||
textInput.className = 'input';
|
||||
textInput.placeholder = `Data Pembanding ${columnCount}`;
|
||||
newCell.appendChild(textInput);
|
||||
}
|
||||
|
||||
// Tambahkan sel baru ke baris
|
||||
row.appendChild(newCell);
|
||||
});
|
||||
});
|
||||
|
||||
document.getElementById('removeColumnBtn').addEventListener('click', function() {
|
||||
if (columnCount > 1) { // Pastikan ada kolom yang bisa dihapus
|
||||
columnCount--; // Decrement jumlah kolom
|
||||
|
||||
|
||||
const headers = document.querySelectorAll('#dataTable thead tr th');
|
||||
headers[headers.length - 1].remove();
|
||||
const rows = document.querySelectorAll('#dataTable tbody tr');
|
||||
rows.forEach(row => {
|
||||
const cells = row.querySelectorAll('td');
|
||||
cells[cells.length - 1].remove();
|
||||
});
|
||||
if (columnCount === 1) {
|
||||
document.getElementById('removeColumnBtn').style.display = 'none';
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
function previewImage(event, imgElementId) {
|
||||
const file = event.target.files[0];
|
||||
const imgElement = document.getElementById(imgElementId);
|
||||
|
||||
if (file) {
|
||||
const reader = new FileReader();
|
||||
reader.onload = function(e) {
|
||||
imgElement.src = e.target.result;
|
||||
imgElement.style.display = 'block';
|
||||
}
|
||||
reader.readAsDataURL(file);
|
||||
}
|
||||
}
|
||||
</script>
|
||||
</div>
|
||||
@endsection
|
||||
|
||||
@@ -139,16 +139,18 @@
|
||||
<span class="form-label">Upload Denah</span>
|
||||
</label>
|
||||
<div class="w-full grid gap-5">
|
||||
<img id="foto_denah"
|
||||
<img id="foto_denah-preview"
|
||||
src="{{ isset($formFoto['foto_denah']) ? asset('storage/' . old('foto_denah', $formFoto['foto_denah'])) : '#' }}"
|
||||
alt="Gambar foto_denah" style="width: 30rem;">
|
||||
alt="Gambar foto_denah" style="{{ isset($formFoto['foto_denah']) ? 'width: 30rem;' : 'display: none;' }}">
|
||||
|
||||
|
||||
<div class="input-group w-full flex gap-2">
|
||||
<input type="file"
|
||||
value="{{ old('foto_denah', isset($formDenah['foto_denah']) ? $formDenah['foto_denah'] : '') }}"
|
||||
name="foto_denah" class="file-input file-input-bordered w-full "
|
||||
accept="image/*">
|
||||
accept="image/*"
|
||||
onchange="previewImage(this, 'foto_denah-preview')"
|
||||
>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -196,6 +198,18 @@
|
||||
|
||||
@push('scripts')
|
||||
<script>
|
||||
function previewImage(input, previewId) {
|
||||
if (input.files && input.files[0]) {
|
||||
var reader = new FileReader();
|
||||
reader.onload = function(e) {
|
||||
$('#' + previewId).attr('src', e.target.result).show();
|
||||
}
|
||||
reader.readAsDataURL(input.files[0]);
|
||||
} else {
|
||||
$('#' + previewId).hide();
|
||||
}
|
||||
}
|
||||
|
||||
function submitDenah() {
|
||||
|
||||
const formElement = $('#formDenah')[0];
|
||||
|
||||
@@ -7,138 +7,134 @@
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Positif</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_positif[]" rows="3">{{ old('fakta_positif.0', $forminspeksi['fakta_positif'][0] ?? '') }}</textarea>
|
||||
|
||||
<em id="error-fakta_positif" class="alert text-danger text-sm"></em>
|
||||
<div id="fakta-positif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_positif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_positif[]" rows="3">{{ old('fakta_positif.0', $forminspeksi['fakta_positif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_positif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-positif-container', 'fakta_positif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Negatif</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_negatif[]" rows="3">{{ old('fakta_negatif.0', $forminspeksi['fakta_negatif'][0] ?? '') }}</textarea>
|
||||
<em id="error-fakta_negatif" class="alert text-danger text-sm"></em>
|
||||
<div id="fakta-negatif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_negatif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_negatif[]" rows="3">{{ old('fakta_negatif.0', $forminspeksi['fakta_negatif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_negatif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-negatif-container', 'fakta_negatif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
<button class="btn btn-primary btn-sm">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Rute Menuju</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="rute_menuju" rows="3">{{ old('rute_menuju.0', $forminspeksi['rute_menuju'][0] ?? '') }}</textarea>
|
||||
<em id="error-rute_menuju" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Rute Menuju</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="rute_menuju" rows="3">{{ old('rute_menuju.0', $forminspeksi['rute_menuju'][0] ?? '') }}</textarea>
|
||||
<em id="error-rute_menuju" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Batas batas</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-1 gap-4 items-center w-full">
|
||||
@php
|
||||
$inputBatas = [];
|
||||
$inputBatas = [
|
||||
[
|
||||
'label' => 'Utara',
|
||||
'index' => 0,
|
||||
'value' => old('batas_batas.0', $forminspeksi['batas_batas'][0] ?? ''),
|
||||
],
|
||||
[
|
||||
'label' => 'Timur',
|
||||
'index' => 1,
|
||||
'value' => $forminspeksi['batas_batas'][1] ?? '',
|
||||
],
|
||||
[
|
||||
'label' => 'Selatan',
|
||||
'index' => 2,
|
||||
'value' => $forminspeksi['batas_batas'][2] ?? '',
|
||||
],
|
||||
[
|
||||
'label' => 'Barat',
|
||||
'index' => 3,
|
||||
'value' => $forminspeksi['batas_batas'][3] ?? '',
|
||||
],
|
||||
];
|
||||
@endphp
|
||||
@if ($inputBatas > 0)
|
||||
@foreach ($inputBatas as $item)
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<input type="text" name="batas_batas[]" class="input"
|
||||
value="{{ $item['value'] }}" />
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
<em id="error-batas_batas" class="alert text-danger text-sm"></em>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Batas batas</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="grid grid-cols-1 gap-4 items-center w-full">
|
||||
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56 gap-2.5" style="width: 500px">
|
||||
<input class="checkbox" name="batas_batas[]" type="checkbox"
|
||||
value="{{ $item->name }}"
|
||||
{{ in_array($item->name, old('batas_batas', $forminspeksi['batas_batas'] ?? [])) ? 'checked' : '' }} />
|
||||
{{ $item->name }}
|
||||
</label>
|
||||
<input type="text" name="batas_batas_input[]" class="input w-full"
|
||||
id="bentukTanahInput" placeholder="Masukkan Batas {{ $item->name }}..."
|
||||
value="{{ old('batas_batas_input.' . $loop->index, $forminspeksi['batas_batas_input'][$loop->index] ?? '') }}">
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
<em id="error-batas_batas" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi lain terkait lingkungan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea class="textarea mt-2" name="kondisi_lingkungan[]" rows="3">{{ old('kondisi_lingkungan.0', $forminspeksi['kondisi_lingkungan'][0] ?? '') }}</textarea>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi lain terkait lingkungan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full" id="kondisi-lingkungan-container">
|
||||
<div class="kondisi_lingkungan flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="kondisi_lingkungan[]" rows="3" placeholder="Tambahkan keterangan"></textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-kondisi_lingkungan" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
<button class="btn btn-primary btn-sm mt-5 ">
|
||||
|
||||
<button class="btn btn-primary btn-sm mt-5" type="button"
|
||||
onclick="addClonableItem('kondisi-lingkungan-container', 'kondisi_lingkungan')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi lain terkait Bangunan</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi lain terkait Bangunan</label>
|
||||
<div id="kondisi-lain-bangunan-container" class="flex flex-wrap items-baseline w-full">
|
||||
|
||||
|
||||
<div class="kondisi_lain_bangunan flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="kondisi_lain_bangunan[]" rows="3">{{ old('kondisi_lain_bangunan.0', $forminspeksi['kondisi_lain_bangunan'][0] ?? '') }}</textarea>
|
||||
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-kondisi_lain_bangunan" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
<button class="btn btn-primary btn-sm mt-5 ">
|
||||
<button type="button"
|
||||
onclick="addClonableItem('kondisi-lain-bangunan-container', 'kondisi_lain_bangunan')"
|
||||
class="btn btn-primary btn-sm mt-5 ">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Informasi Terkait Dokumen</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Informasi Terkait Dokumen</label>
|
||||
<div id="informasi-dokument-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="informasi_dokument flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="informasi_dokument" rows="3">{{ old('informasi_dokument.0', $forminspeksi['informasi_dokument'][0] ?? '') }}</textarea>
|
||||
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-informasi_dokument" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
<button class="btn btn-primary btn-sm mt-5 ">
|
||||
<button class="btn btn-primary btn-sm mt-5 " type="button"
|
||||
onclick="addClonableItem('informasi-dokument-container', 'informasi_dokument')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<script>
|
||||
function previewImage(input, previewId) {
|
||||
if (input.files && input.files[0]) {
|
||||
var reader = new FileReader();
|
||||
reader.onload = function(e) {
|
||||
$('#' + previewId).attr('src', e.target.result).show();
|
||||
}
|
||||
reader.readAsDataURL(input.files[0]);
|
||||
} else {
|
||||
$('#' + previewId).hide();
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -45,15 +45,14 @@
|
||||
<input type="text" class="input form-control" name="debitur_perwakilan[]"
|
||||
value="{{ old('debitur_perwakilan', isset($forminspeksi['debitur_perwakilan']) ? implode(', ', $forminspeksi['debitur_perwakilan']) : '') }}"
|
||||
placeholder="Masukkan Debitur/Perwakilan" />
|
||||
<button type="button" class="btn btn-danger btn-outline btn-xs delete-button"
|
||||
<button type="button" class="btn btn-danger btn-outline btn-xs remove-btn"
|
||||
style="display: none">Hapus</button>
|
||||
</div>
|
||||
</div>
|
||||
<button id="addPerwakilan" type="button" class="btn-md btn btn-primary">
|
||||
<button onclick="addClonableItem('perwakilan', 'perwakilan')" type="button" class="btn-md btn btn-primary">
|
||||
<i class="ki-filled ki-plus"></i>
|
||||
</button>
|
||||
<em id="error-debitur_perwakilan" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -187,8 +187,9 @@
|
||||
<input id="foto_tempat" type="file" name="foto_tempat"
|
||||
|
||||
class="file-input file-input-bordered w-full" accept="image/*"
|
||||
onchange="previewImage(this, 'argis-region-preview')">
|
||||
<img id="argis-region-preview"
|
||||
onchange="previewImage(this, 'foto_tempat-preview')">
|
||||
|
||||
<img id="foto_tempat-preview"
|
||||
src="{{ asset('storage/' . (isset($forminspeksi['foto_tempat']) ? $forminspeksi['foto_tempat'] : '')) }}"
|
||||
alt="Foto Argis Region" class="mt-2 max-w-full h-auto"
|
||||
style="{{ isset($forminspeksi['foto_tempat']) ? '' : 'display: none;' }}">
|
||||
|
||||
@@ -34,25 +34,25 @@
|
||||
|
||||
|
||||
@foreach ($permohonan->debiture->documents as $dokumen)
|
||||
@if ($dokumen->jenisJaminan)
|
||||
@php
|
||||
$formKategori = json_decode($dokumen->jenisJaminan->form_kategori, true);
|
||||
@endphp
|
||||
@if (isset($formKategori) && $formKategori)
|
||||
<input type="hidden" name="action"
|
||||
value="{{ is_array($formKategori) ? implode(',', $formKategori) : $formKategori }}">
|
||||
<input type="hidden" name="type"
|
||||
value="{{ is_array($formKategori) ? implode(',', $formKategori) : $formKategori }}">
|
||||
@if (is_array($formKategori))
|
||||
@foreach ($formKategori as $kategori)
|
||||
@include('lpj::surveyor.components.' . str_replace('-', '-', $kategori), [
|
||||
'dokumen' => $dokumen,
|
||||
])
|
||||
@endforeach
|
||||
@if ($dokumen->jenisJaminan)
|
||||
@php
|
||||
$formKategori = json_decode($dokumen->jenisJaminan->form_kategori, true);
|
||||
@endphp
|
||||
@if (isset($formKategori) && $formKategori)
|
||||
<input type="hidden" name="action"
|
||||
value="{{ is_array($formKategori) ? implode(',', $formKategori) : $formKategori }}">
|
||||
<input type="hidden" name="type"
|
||||
value="{{ is_array($formKategori) ? implode(',', $formKategori) : $formKategori }}">
|
||||
@if (is_array($formKategori))
|
||||
@foreach ($formKategori as $kategori)
|
||||
@include('lpj::surveyor.components.' . str_replace('-', '-', $kategori), [
|
||||
'dokumen' => $dokumen,
|
||||
])
|
||||
@endforeach
|
||||
@endif
|
||||
@endif
|
||||
@endif
|
||||
@endif
|
||||
@endforeach
|
||||
@endforeach
|
||||
|
||||
<div class="flex justify-end gap-2" style="margin-right: 20px; margin-top: 20px">
|
||||
<button type="button" class="btn btn-success" id="saveButton" onclick="submitData()">
|
||||
@@ -169,4 +169,44 @@
|
||||
});
|
||||
}
|
||||
</script>
|
||||
|
||||
<script>
|
||||
function previewImage(input, previewId) {
|
||||
if (input.files && input.files[0]) {
|
||||
var reader = new FileReader();
|
||||
reader.onload = function(e) {
|
||||
$('#' + previewId).attr('src', e.target.result).show();
|
||||
}
|
||||
reader.readAsDataURL(input.files[0]);
|
||||
} else {
|
||||
$('#' + previewId).hide();
|
||||
}
|
||||
}
|
||||
|
||||
function addClonableItem(containerId, itemClass) {
|
||||
const container = document.getElementById(containerId);
|
||||
if (!container) {
|
||||
console.error(`Container with ID "${containerId}" not found.`);
|
||||
return;
|
||||
}
|
||||
|
||||
const template = container.querySelector(`.${itemClass}`);
|
||||
if (!template) {
|
||||
console.error(`Template with class "${itemClass}" not found in container "${containerId}".`);
|
||||
return;
|
||||
}
|
||||
|
||||
const newElement = template.cloneNode(true);
|
||||
const inputs = newElement.querySelectorAll('input, textarea');
|
||||
inputs.forEach(input => (input.value = ''));
|
||||
|
||||
const deleteButton = newElement.querySelector('.remove-btn');
|
||||
if (deleteButton) {
|
||||
deleteButton.style.display = 'inline-block';
|
||||
deleteButton.addEventListener('click', () => newElement.remove());
|
||||
}
|
||||
|
||||
container.appendChild(newElement);
|
||||
}
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -1,27 +1,97 @@
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Identitas Debitur</h1>
|
||||
</div>
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Order Penilaian</h1>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="hub_calon_debitur" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
<div class="grid gap-5 grid-cols-2">
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tujuan Penilaian</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->tujuanPenilaian))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->tujuanPenilaian->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tanggal Survey</label>
|
||||
<div class="flex flex-wrap items-base line w-full">
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->created_at->format('d/m/Y') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Cab/Direktorat</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->branch))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->branch->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">AO</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->user))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->user->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@error('hub_calon_debitur')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- lokasi jaminan --}}
|
||||
@include('lpj::surveyor.components.lokasi-jaminan')
|
||||
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Identitas Debitur</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->debiture->name))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->debiture->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Wakil Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="nama_wakil" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
<em id="error-nama_wakil" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="hub_calon_debitur" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
<em id="error-hub_calon_debitur" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- lokasi jaminan --}}
|
||||
@include('lpj::surveyor.components.lokasi-jaminan')
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Data Data Jaminan</h1>
|
||||
@@ -43,7 +113,7 @@
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
@@ -64,7 +134,7 @@
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
@@ -85,7 +155,7 @@
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
@@ -107,34 +177,109 @@
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$inputDataJaminan = [];
|
||||
|
||||
$inputDataJaminan = [
|
||||
['label' => 'Nama Kapal', 'index' => 0],
|
||||
['label' => 'Pemilik Kapal', 'index' => 1],
|
||||
['label' => 'Bendera', 'index' => 2],
|
||||
['label' => 'Nomor Tanda Selar', 'index' => 3],
|
||||
['label' => 'Kapal', 'index' => 4],
|
||||
['label' => 'Galangan', 'index' => 5],
|
||||
['label' => 'Kapal/Shipyard', 'index' => 6],
|
||||
['label' => 'Tahun Pembuatan', 'index' => 7],
|
||||
['label' => 'Tahun Lanuncing', 'index' => 8],
|
||||
['label' => 'DWT (ton)', 'index' => 9],
|
||||
['label' => 'LWT (ton)', 'index' => 10],
|
||||
['label' => 'Gross Tonnage (ton)', 'index' => 11],
|
||||
['label' => 'Net Tonnage (ton)', 'index' => 12],
|
||||
['label' => 'Tenaga Mesin (HP)', 'index' => 13],
|
||||
['label' => 'LOA', 'index' => 14],
|
||||
['label' => 'LBP', 'index' => 15],
|
||||
['label' => 'Beam', 'index' => 16],
|
||||
['label' => 'Depth', 'index' => 17],
|
||||
['label' => 'Draft', 'index' => 18],
|
||||
[
|
||||
'label' => 'Nama Kapal',
|
||||
'name' => 'nama_kapal',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Pemilik Kapal',
|
||||
'name' => 'pemilik_kapal',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Bendera',
|
||||
'name' => 'bendera',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Tanda Selar',
|
||||
'name' => 'nomor_selar',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Kapal',
|
||||
'name' => 'kapal',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Galangan',
|
||||
'name' => 'galangan_kapal',
|
||||
'index' => 5,
|
||||
],
|
||||
[
|
||||
'label' => 'Kapal/Shipyard',
|
||||
'name' => 'kapal_shipyard',
|
||||
'index' => 6,
|
||||
],
|
||||
[
|
||||
'label' => 'Tahun Pembuatan',
|
||||
'name' => 'tahun_pembuatan',
|
||||
'index' => 7,
|
||||
],
|
||||
[
|
||||
'label' => 'Tahun Lanuncing',
|
||||
'name' => 'tahun_launcing',
|
||||
'index' => 8,
|
||||
],
|
||||
[
|
||||
'label' => 'DWT (ton)',
|
||||
'name' => 'dwt',
|
||||
'index' => 9,
|
||||
],
|
||||
[
|
||||
'label' => 'LWT (ton)',
|
||||
'name' => 'lwt',
|
||||
'index' => 10,
|
||||
],
|
||||
[
|
||||
'label' => 'Gross Tonnage (ton)',
|
||||
'name' => 'gross_tonnage',
|
||||
'index' => 11,
|
||||
],
|
||||
[
|
||||
'label' => 'Net Tonnage (ton)',
|
||||
'name' => 'net_tonnage',
|
||||
'index' => 12,
|
||||
],
|
||||
[
|
||||
'label' => 'Tenaga Mesin (HP)',
|
||||
'name' => 'tenaga_mesin',
|
||||
'index' => 13,
|
||||
],
|
||||
[
|
||||
'label' => 'LOA',
|
||||
'name' => 'loa',
|
||||
'index' => 14,
|
||||
],
|
||||
[
|
||||
'label' => 'LBP',
|
||||
'name' => 'lbp',
|
||||
'index' => 15,
|
||||
],
|
||||
[
|
||||
'label' => 'Beam',
|
||||
'name' => 'beam',
|
||||
'index' => 16,
|
||||
],
|
||||
[
|
||||
'label' => 'Depth',
|
||||
'name' => 'depth',
|
||||
'index' => 17,
|
||||
],
|
||||
[
|
||||
'label' => 'Draft',
|
||||
'name' => 'draft',
|
||||
'index' => 18,
|
||||
],
|
||||
];
|
||||
@endphp
|
||||
|
||||
@@ -144,24 +289,16 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
|
||||
<div class="flex justify-end" style="margin-top: 10px">
|
||||
<button class="btn btn-xs btn-primary" type="button" id="addBagunan">
|
||||
tambah mesin
|
||||
<i class="ki-filled ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
@@ -170,33 +307,64 @@
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
$inputDataLoaksi = [];
|
||||
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Lambung Kapal', 'index' => 0],
|
||||
['label' => 'Dek', 'index' => 1],
|
||||
['label' => 'Struktur Rangka', 'index' => 2],
|
||||
['label' => 'Palka', 'index' => 3],
|
||||
['label' => 'Pondasi Mesin', 'index' => 4],
|
||||
['label' => 'Area Mesin', 'index' => 5],
|
||||
['label' => 'Cat dan Korosi', 'index' => 6],
|
||||
['label' => 'Sistem Pengelasan', 'index' => 7]
|
||||
$inputStrukturKapal = [
|
||||
[
|
||||
'label' => 'Lambung Kapal',
|
||||
'name' => 'lambung_kapal',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Dek',
|
||||
'name' => 'dek',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Struktur Rangka',
|
||||
'name' => 'struktur_rangka',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Palka',
|
||||
'name' => 'palka',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Pondasi Mesin',
|
||||
'name' => 'pondasi_mesin',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Area Mesin',
|
||||
'name' => 'area_mesin',
|
||||
'index' => 5,
|
||||
],
|
||||
[
|
||||
'label' => 'Cat dan Korosi',
|
||||
'name' => 'cat_dan_korosi',
|
||||
'index' => 6,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Pengelasan',
|
||||
'name' => 'sistem_pengelasan',
|
||||
'index' => 7,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataLoaksi) > 0)
|
||||
@foreach ($inputDataLoaksi as $item)
|
||||
@if (count($inputStrukturKapal) > 0)
|
||||
@foreach ($inputStrukturKapal as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -204,10 +372,10 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<textarea name="deskripsi_struktur" id="" class="textarea"></textarea>
|
||||
|
||||
<em id="error_deskripsi_struktur" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -220,33 +388,60 @@
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
$inputDataLoaksi = [];
|
||||
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Sekoci/Lifeboat', 'index' => 0],
|
||||
['label' => 'Jaket Pelampung', 'index' => 1],
|
||||
['label' => 'Alat Pemadam', 'index' => 2],
|
||||
['label' => 'Rambu Darurat', 'index' => 3],
|
||||
['label' => 'Sistem Alarm', 'index' => 4],
|
||||
['label' => 'Sistem Pencegah', 'index' => 5],
|
||||
['label' => 'Kebaran', 'index' => 6],
|
||||
['label' => 'Lampu Darurat', 'index' => 7]
|
||||
$inputPeralatan = [
|
||||
[
|
||||
'label' => 'Sekoci/Lifeboat',
|
||||
'name' => 'sekoci',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Jaket Pelampung',
|
||||
'name' => 'jaket_pelampung',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Alat Pemadam',
|
||||
'name' => 'alat_pemadaman',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Rambu Darurat',
|
||||
'name' => 'rambu_darurat',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Alarm',
|
||||
'name' => 'sistem_alarm',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Pencegah',
|
||||
'name' => 'sistem_pencegah',
|
||||
'index' => 5,
|
||||
],
|
||||
[
|
||||
'label' => 'Kebakaran',
|
||||
'name' => 'kebakaran',
|
||||
'index' => 6,
|
||||
],
|
||||
[
|
||||
'label' => 'Lampu Darurat',
|
||||
'name' => 'lampu_darurat',
|
||||
'index' => 7,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataLoaksi) > 0)
|
||||
@foreach ($inputDataLoaksi as $item)
|
||||
@if (count($inputPeralatan) > 0)
|
||||
@foreach ($inputPeralatan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -254,10 +449,10 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<textarea name="deskripsi_peralatan" id="" class="textarea"></textarea>
|
||||
|
||||
<em id="error_deskripsi_peralatan" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -270,15 +465,38 @@
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
$inputDataLoaksi = [];
|
||||
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Gps', 'index' => 0],
|
||||
['label' => 'Radat', 'index' => 1],
|
||||
['label' => 'Radio Komunikasi', 'index' => 2],
|
||||
['label' => 'Lampu Navigasi', 'index' => 3],
|
||||
['label' => 'Sistem Kendali otomatis', 'index' => 4],
|
||||
['label' => 'Kompas', 'index' => 5],
|
||||
[
|
||||
'label' => 'Gps',
|
||||
'name' => 'gps',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Radar',
|
||||
'name' => 'radar',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Radio Komunikasi',
|
||||
'name' => 'radio_komunikasi',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Lampu Navigasi',
|
||||
'name' => 'lampu_navigasi',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Kendali otomatis',
|
||||
'name' => 'sistem_kendali_otomatis',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Kompas',
|
||||
'name' => 'kompas',
|
||||
'index' => 5,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
@@ -289,12 +507,11 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -302,10 +519,8 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<textarea name="deskripsi_navigasi" id="" class="textarea"></textarea>
|
||||
<em id="error_deskripsi_navigasi" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -319,31 +534,51 @@
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
$inputDataLoaksi = [];
|
||||
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Mesin Utama', 'index' => 0],
|
||||
['label' => 'Mesin Bantu', 'index' => 1],
|
||||
['label' => 'Pompa Pendingin', 'index' => 2],
|
||||
['label' => 'Sistem Pelumasan', 'index' => 3],
|
||||
['label' => 'Propeller', 'index' => 4],
|
||||
['label' => 'Sistem Kelistrikan', 'index' => 5],
|
||||
$inputSistemPengerak = [
|
||||
[
|
||||
'label' => 'Mesin Utama',
|
||||
'name' => 'mesin_utama',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Mesin Bantu',
|
||||
'name' => 'mesin_bantu',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Pompa Pendingin',
|
||||
'name' => 'pompa_pendingin',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Pelumasan',
|
||||
'name' => 'sistem_pelumasan',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Propeller',
|
||||
'name' => 'propeller',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Kelistrikan',
|
||||
'name' => 'sistem_kelistrikan',
|
||||
'index' => 5,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataLoaksi) > 0)
|
||||
@foreach ($inputDataLoaksi as $item)
|
||||
@if (count($inputSistemPengerak) > 0)
|
||||
@foreach ($inputSistemPengerak as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -351,10 +586,8 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<textarea name="deskripsi_mesin_penggerak" id="" class="textarea"></textarea>
|
||||
<em id="error_deskripsi_mesin_penggerak" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -368,29 +601,45 @@
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
$inputDataLoaksi = [];
|
||||
$inputSistemKelistrikan = [];
|
||||
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Lampu Navigasi', 'index' => 0],
|
||||
['label' => 'Sistem Penerangan', 'index' => 1],
|
||||
['label' => 'Sistem Panel Distribusi', 'index' => 2],
|
||||
['label' => 'Kabel dan Perangkat Pendukung', 'index' => 3],
|
||||
$inputSistemKelistrikan = [
|
||||
[
|
||||
'label' => 'Lampu Navigasi',
|
||||
'name' => 'lampu_navigasi',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Penerangan',
|
||||
'name' => 'sistem_penerangan',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Panel Distribusi',
|
||||
'name' => 'sistem_panel_distribusi',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Kabel dan Perangkat Pendukung',
|
||||
'name' => 'kabel_perangkat',
|
||||
'index' => 3,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataLoaksi) > 0)
|
||||
@foreach ($inputDataLoaksi as $item)
|
||||
@if (count($inputSistemKelistrikan) > 0)
|
||||
@foreach ($inputSistemKelistrikan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -398,10 +647,10 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<textarea name="deskripsi_kelistrikan" id="" class="textarea"></textarea>
|
||||
|
||||
<em id="error_deskripsi_kelistrikan" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -414,19 +663,35 @@
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
@php
|
||||
$inputDataLoaksi = [];
|
||||
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Kebersihan Dek Luar', 'index' => 0],
|
||||
['label' => 'Tangki Limbah', 'index' => 1],
|
||||
['label' => 'Sistem Pengelolaan Limbah', 'index' => 2],
|
||||
['label' => 'Pengelolaan Air Ballast', 'index' => 3],
|
||||
|
||||
$inputLinkungan = [
|
||||
[
|
||||
'label' => 'Kebersihan Dek Luar',
|
||||
'name' => 'kebersihan_dek_luar',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Tangki Limbah',
|
||||
'name' => 'tangki_limbah',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Sistem Pengelolaan Limbah',
|
||||
'name' => 'sistem_pengelolaan_limbah',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Pengelolaan Air Ballast',
|
||||
'name' => 'pengelolaan_air_ballast',
|
||||
'index' => 3,
|
||||
],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataLoaksi) > 0)
|
||||
@foreach ($inputDataLoaksi as $item)
|
||||
@if (count($inputLinkungan) > 0)
|
||||
@foreach ($inputLinkungan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
@@ -434,9 +699,9 @@
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
|
||||
<em id="error_{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@@ -444,11 +709,78 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<textarea name="deskripsi_kebersihan" id="" class="textarea"></textarea>
|
||||
|
||||
<em id="error_deskripsi_kebersihan" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card bg-white rounded-lg overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class=" py-4 ">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisis Fakta</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Positif</label>
|
||||
<div id="fakta-positif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_positif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_positif[]" rows="3">{{ old('fakta_positif.0', $forminspeksi['fakta_positif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_positif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-positif-container', 'fakta_positif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Negatif</label>
|
||||
<div id="fakta-negatif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_negatif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_negatif[]" rows="3">{{ old('fakta_negatif.0', $forminspeksi['fakta_negatif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_negatif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-negatif-container', 'fakta_negatif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Catatan Yang Perlu Diperhatikan</label>
|
||||
<div id="catatan-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="catatan flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="catatan[]" rows="3">{{ old('catatan.0', $forminspeksi['catatan'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-catatan" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button"
|
||||
onclick="addClonableItem('catatan-container', 'catatan')"
|
||||
class="btn btn-primary btn-sm mt-5 ">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -46,11 +46,9 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5 mt-5">
|
||||
<label class="form-label max-w-56">Tanggal Survey</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="date" name="tanggal_survey" class="input" placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<input type="date" name="tanggal_survey" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
<em id="error-tanggal_survey" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -77,23 +75,21 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Wakil Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="nama_wakil" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<em id="error-nama_wakil" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
<input type="text" name="hub_calon_debitur" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<em id="error-hub_calon_debitur" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -132,15 +128,51 @@
|
||||
|
||||
@php
|
||||
$inputDataJaminan = [
|
||||
['label' => 'Nama pemilik','index' => 0],
|
||||
['label' => 'Nomor polisi', 'index' => 1],
|
||||
['label' => 'Merek', 'index' => 2],
|
||||
['label' => 'jenis', 'index' => 3],
|
||||
['label' => 'Warna', 'index' => 4],
|
||||
['label' => 'Nomor Rangka/NIK/VIN', 'index' => 5],
|
||||
['label' => 'Nomor Mesin', 'index' => 6],
|
||||
['label' => 'Masa Berlaku STNK', 'index' => 7],
|
||||
['label' => 'Masa Berlaku Pajak', 'index' => 8],
|
||||
[
|
||||
'label' => 'Nama pemilik',
|
||||
'name' => 'nama_pemilik',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor polisi',
|
||||
'name' => 'nomor_polisi_jaminan',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Merek',
|
||||
'name' => 'merek_jaminan',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'jenis',
|
||||
'name' => 'jenis',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Warna',
|
||||
'name' => 'warna_jaminan',
|
||||
'index' => 4,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Rangka/NIK/VIN',
|
||||
'name' => 'nomor_rangka_jaminan',
|
||||
'index' => 5,
|
||||
],
|
||||
[
|
||||
'label' => 'Nomor Mesin',
|
||||
'name' => 'nomor_mesin_jaminan',
|
||||
'index' => 6,
|
||||
],
|
||||
[
|
||||
'label' => 'Masa Berlaku STNK',
|
||||
'name' => 'masa_stnk',
|
||||
'index' => 7,
|
||||
],
|
||||
[
|
||||
'label' => 'Masa Berlaku Pajak',
|
||||
'name' => 'masa_pajak',
|
||||
'index' => 8,
|
||||
],
|
||||
];
|
||||
@endphp
|
||||
|
||||
@@ -175,9 +207,9 @@
|
||||
@foreach ($saranaPelengkap as $item)
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56 gap-2.5" style="width: 500px">
|
||||
<input class="checkbox" name="sarana_pelengkap[]" type="checkbox"
|
||||
<input class="checkbox" name="kendaraan[]" type="checkbox"
|
||||
value="{{ $item->name }}"
|
||||
{{ in_array($item->name, old('sarana_pelengkap', $forminspeksi['sarana_pelengkap'] ?? [])) ? 'checked' : '' }} />
|
||||
{{ in_array($item->name, old('kendaraan', $forminspeksi['kendaraan'] ?? [])) ? 'checked' : '' }} />
|
||||
{{ $item->name }}
|
||||
</label>
|
||||
<input type="text" name="sarana_pelengkap_input[]" class="input w-full"
|
||||
@@ -187,17 +219,16 @@
|
||||
@endforeach
|
||||
@endif
|
||||
</div>
|
||||
<em id="error-sarana_pelengkap" class="alert text-danger text-sm"></em>
|
||||
<em id="error-kendaraan" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kondisi</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="tanggal_survey" class="input" placeholder="STNK">
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<input type="text" name="kondisi" class="input" placeholder="Masukkan Kondisi">
|
||||
<em id="error-kondisi" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -210,9 +241,9 @@
|
||||
@foreach ($permohonan->debiture->documents as $item)
|
||||
@php
|
||||
$details = json_decode($item->detail);
|
||||
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
|
||||
$nomo_polisi = isset($details['nomo_polisi']) ? $details['nomo_polisi'] : 'N/A';
|
||||
@endphp
|
||||
<p class="text-2sm text-gray-700">{{ $luas_tanah }} </p>
|
||||
<p class="text-2sm text-gray-700">{{ $nomo_polisi }} </p>
|
||||
@endforeach
|
||||
@endif
|
||||
<div class="flex-wrap items-stretch">
|
||||
@@ -248,9 +279,9 @@
|
||||
@foreach ($permohonan->debiture->documents as $item)
|
||||
@php
|
||||
$details = json_decode($item->detail);
|
||||
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
|
||||
$merek = isset($details['merek']) ? $details['merek'] : 'N/A';
|
||||
@endphp
|
||||
<p class="text-2sm text-gray-700">{{ $luas_tanah }} </p>
|
||||
<p class="text-2sm text-gray-700">{{ $merek }} </p>
|
||||
@endforeach
|
||||
@endif
|
||||
<div class="flex-wrap items-stretch">
|
||||
@@ -273,7 +304,7 @@
|
||||
value="{{ old('merek_tidak_sesuai', $forminspeksi['merek_tidak_sesuai'] ?? '') }}"
|
||||
style="{{ old('merek', $forminspeksi['merek'] ?? '') == 'tidak sesuai' ? '' : 'display: none;' }}">
|
||||
</div>
|
||||
<em id="error-luas_tanah" class="alert text-danger text-sm"></em>
|
||||
<em id="error-merek" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -287,9 +318,9 @@
|
||||
@foreach ($permohonan->debiture->documents as $item)
|
||||
@php
|
||||
$details = json_decode($item->detail);
|
||||
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
|
||||
$warna = isset($details['warna']) ? $details['warna'] : 'N/A';
|
||||
@endphp
|
||||
<p class="text-2sm text-gray-700">{{ $luas_tanah }} </p>
|
||||
<p class="text-2sm text-gray-700">{{ $warna }} </p>
|
||||
@endforeach
|
||||
@endif
|
||||
<div class="flex-wrap items-stretch">
|
||||
@@ -326,9 +357,9 @@
|
||||
@foreach ($permohonan->debiture->documents as $item)
|
||||
@php
|
||||
$details = json_decode($item->detail);
|
||||
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
|
||||
$nomor_rangka = isset($details['nomor_rangka']) ? $details['nomor_rangka'] : 'N/A';
|
||||
@endphp
|
||||
<p class="text-2sm text-gray-700">{{ $luas_tanah }} </p>
|
||||
<p class="text-2sm text-gray-700">{{ $nomor_rangka }} </p>
|
||||
@endforeach
|
||||
@endif
|
||||
<div class="flex-wrap items-stretch">
|
||||
@@ -364,9 +395,9 @@
|
||||
@foreach ($permohonan->debiture->documents as $item)
|
||||
@php
|
||||
$details = json_decode($item->detail);
|
||||
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
|
||||
$nomor_mesin = isset($details['nomor_mesin']) ? $details['nomor_mesin'] : 'N/A';
|
||||
@endphp
|
||||
<p class="text-2sm text-gray-700">{{ $luas_tanah }} </p>
|
||||
<p class="text-2sm text-gray-700">{{ $nomor_mesin }} </p>
|
||||
@endforeach
|
||||
@endif
|
||||
<div class="flex-wrap items-stretch">
|
||||
@@ -400,9 +431,9 @@
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Posisi Kilometer</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="tanggal_survey" class="input" placeholder="Posisi Kilometer">
|
||||
<input type="text" name="posisi_kilometer" class="input" placeholder="Posisi Kilometer">
|
||||
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
<em id="error-posisi_kilometer" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -572,12 +603,12 @@
|
||||
@endif
|
||||
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Perusahaan Asuransi</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="perusahaan_asuransi" class="input" placeholder="Pesurahaan Asuransi">
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
<input type="text" name="perusahaan_asuransi" class="input"
|
||||
placeholder="Pesurahaan Asuransi">
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@@ -586,10 +617,113 @@
|
||||
<label class="form-label max-w-56">Tahun Berakhir</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="date" name="tahun_berakhir" class="input" placeholder="Tahun berakhir">
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
<em class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card bg-white rounded-lg overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class=" py-4 ">
|
||||
<h1 class="text-md font-medium text-gray-900">Analisis Fakta</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Positif</label>
|
||||
<div id="fakta-positif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_positif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_positif[]" rows="3">{{ old('fakta_positif.0', $forminspeksi['fakta_positif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_positif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-positif-container', 'fakta_positif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Faktor Negatif</label>
|
||||
<div id="fakta-negatif-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="fakta_negatif flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="fakta_negatif[]" rows="3">{{ old('fakta_negatif.0', $forminspeksi['fakta_negatif'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-fakta_negatif" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button" class="btn btn-primary btn-sm mt-5"
|
||||
onclick="addClonableItem('fakta-negatif-container', 'fakta_negatif')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Analisa makro</label>
|
||||
<div class="flex flex-wrap items-baseline w-full" id="analisa-makro-container">
|
||||
<div class="analisa_makro flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="analisa_makro[]" rows="3" placeholder="Tambahkan keterangan"></textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-analisa_makro" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
|
||||
<button class="btn btn-primary btn-sm mt-5" type="button"
|
||||
onclick="addClonableItem('analisa-makro-container', 'analisa_makro')">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Kesimpulan</label>
|
||||
<div id="kesimpulan-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="kesimpulan flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="kesimpulan[]" rows="3">{{ old('kesimpulan.0', $forminspeksi['kesimpulan'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-kesimpulan" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button"
|
||||
onclick="addClonableItem('kesimpulan-container', 'kesimpulan')"
|
||||
class="btn btn-primary btn-sm mt-5 ">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Catatan Lainnya</label>
|
||||
<div id="catatan-container" class="flex flex-wrap items-baseline w-full">
|
||||
<div class="catatan flex items-center gap-2 mt-2 textarea-group w-full">
|
||||
<textarea class="textarea mt-2" name="catatan[]" rows="3">{{ old('catatan.0', $forminspeksi['catatan'][0] ?? '') }}</textarea>
|
||||
<button class="btn btn-danger btn-sm remove-btn" type="button" style="display: none;">
|
||||
<i class="ki-outline ki-trash"></i>
|
||||
</button>
|
||||
<em id="error-catatan" class="alert text-danger text-sm"></em>
|
||||
</div>
|
||||
<button type="button"
|
||||
onclick="addClonableItem('catatan-container', 'catatan')"
|
||||
class="btn btn-primary btn-sm mt-5 ">
|
||||
<i class="ki-outline ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -8,13 +8,13 @@
|
||||
|
||||
$inputDataLoaksi = [];
|
||||
$inputDataLoaksi = [
|
||||
['label' => 'Nama Jalan', 'index' => 0, 'name' => 'nama_jalan', 'value' => old('lokasi_jalan', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_jalan : '')],
|
||||
['label' => 'Nama Jalan', 'index' => 0, 'name' => 'nama_jalan', 'value' => old('nama_jalan', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_jalan : '')],
|
||||
['label' => 'Perumahan/Gang', 'index' => 1, 'name' => 'perumahan_gang', 'value' => old('lokasi_perumahan_gang', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_perumahan_gang : '')],
|
||||
['label' => 'Blok/Nomor', 'index' => 2, 'name' => 'blok_nomor', 'value' => old('lokasi_blok_nomor', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_blok_nomor : '')],
|
||||
['label' => 'Desa/Kelurahan', 'index' => 3, 'name' => 'desa_kelurahan', 'value' => old('lokasi_desa_kelurahan', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_desa_kelurahan : '')],
|
||||
['label' => 'Kecamatan', 'index' => 4, 'name' => 'kecamatan' , 'value' => old('lokasi_kecamatan', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_kecamatan : '')],
|
||||
['label' => 'Kota/Kotamadya', 'index' => 5, 'name' => 'kota_kotamadya', 'value' => old('lokasi_kota_kotamadya', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_kota_kotamadya : '')],
|
||||
['label' => 'Provinsi', 'index' => 6, 'name' => 'provinsi', 'value' => old('lokasi_provinsi', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_provinsi : '')],
|
||||
['label' => 'Blok/Nomor', 'index' => 2, 'name' => 'blok_nomor', 'value' => old('blok_nomor', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_blok_nomor : '')],
|
||||
['label' => 'Desa/Kelurahan', 'index' => 3, 'name' => 'desa_kelurahan', 'value' => old('desa_kelurahan', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_desa_kelurahan : '')],
|
||||
['label' => 'Kecamatan', 'index' => 4, 'name' => 'kecamatan' , 'value' => old('kecamatan', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_kecamatan : '')],
|
||||
['label' => 'Kota/Kotamadya', 'index' => 5, 'name' => 'kota_madya', 'value' => old('kota_madya', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_kota_kotamadya : '')],
|
||||
['label' => 'Provinsi', 'index' => 6, 'name' => 'provinsi', 'value' => old('provinsi', isset($analisa->analisaLingkungan) ? $analisa->analisaLingkungan->lokasi_provinsi : '')],
|
||||
];
|
||||
|
||||
@endphp
|
||||
|
||||
@@ -1,99 +1,188 @@
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Identitas Debitur</h1>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Order Penilaian</h1>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- lokasi jaminan --}}
|
||||
@include('lpj::surveyor.components.lokasi-jaminan')
|
||||
</div>
|
||||
<div class="grid gap-5 grid-cols-2">
|
||||
|
||||
|
||||
<div class=""max-w-4xl mx-auto bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Data Data Jaminan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Model</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select class="input tomselect w-full @error('hadapMataAngin') border-danger bg-danger-light @enderror"
|
||||
name="hadapMataAngin">
|
||||
<option value="">Select Model Kendaraan </option>
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->name }}"
|
||||
{{ old('hadapMataAngin') == $item->name ? 'selected' : '' }}>{{ $item->name }}
|
||||
</option>
|
||||
@endforeach
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tujuan Penilaian</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->tujuanPenilaian))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->tujuanPenilaian->name }}</p>
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$inputDataJaminan = [];
|
||||
|
||||
$inputDataJaminan = [
|
||||
['label' => 'Tipe/Model', 'index' => 0],
|
||||
['label' => 'Merek', 'index' => 1],
|
||||
['label' => 'Tahun Pembuatan', 'index' => 2],
|
||||
['label' => 'Negara Pembuat', 'index' => 3],
|
||||
['label' => 'Kondisi Mesin', 'index' => 4],
|
||||
];
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataJaminan) > 0)
|
||||
@foreach ($inputDataJaminan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="bentuk_tanah" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
@error('bentuk_tanah')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Tanggal Survey</label>
|
||||
<div class="flex flex-wrap items-base line w-full">
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->created_at->format('d/m/Y') }}</p>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex justify-end" style="margin-top: 10px">
|
||||
<button class="btn btn-xs btn-primary" type="button" id="addBagunan">
|
||||
tambah mesin
|
||||
<i class="ki-filled ki-plus"></i>
|
||||
</button>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Cab/Direktorat</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->branch))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->branch->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">AO</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->user))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->user->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Identitas Debitur</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
@if (isset($permohonan->debiture->name))
|
||||
<p class="text-2sm text-gray-700">{{ $permohonan->debiture->name }}</p>
|
||||
@endif
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Nama Wakil Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="nama_wakil" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
<em id="error-nama_wakil" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Hubungan Calon Debitur</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="hub_calon_debitur" class="input"
|
||||
placeholder="Masukkan Hubungan Calon Debitur">
|
||||
|
||||
|
||||
<em id="error-hub_calon_debitur" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{-- lokasi jaminan --}}
|
||||
@include('lpj::surveyor.components.lokasi-jaminan')
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
<div class="card bg-white rounded-lg shadow-md overflow-hidden">
|
||||
<div class="card-body">
|
||||
<div class="py-4 px-6">
|
||||
<h1 class="text-md font-medium text-gray-900">Data Data Jaminan</h1>
|
||||
</div>
|
||||
<div class="grid gap-5">
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Model</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<select
|
||||
class="input tomselect w-full @error('hadapMataAngin') border-danger bg-danger-light @enderror"
|
||||
name="hadapMataAngin">
|
||||
<option value="">Select Model Kendaraan </option>
|
||||
@if (isset($arahMataAngin))
|
||||
@foreach ($arahMataAngin as $item)
|
||||
<option value="{{ $item->name }}"
|
||||
{{ old('hadapMataAngin') == $item->name ? 'selected' : '' }}>{{ $item->name }}
|
||||
</option>
|
||||
@endforeach
|
||||
@endif
|
||||
</select>
|
||||
|
||||
@error('hadapMataAngin')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@php
|
||||
$inputDataJaminan = [];
|
||||
|
||||
$inputDataJaminan = [
|
||||
[
|
||||
'label' => 'Tipe/Model',
|
||||
'name' => 'tipe_model',
|
||||
'index' => 0,
|
||||
],
|
||||
[
|
||||
'label' => 'Merek',
|
||||
'name' => 'merek',
|
||||
'index' => 1,
|
||||
],
|
||||
[
|
||||
'label' => 'Tahun Pembuatan',
|
||||
'name' => 'tahun_pembuatan',
|
||||
'index' => 2,
|
||||
],
|
||||
[
|
||||
'label' => 'Negara Pembuat',
|
||||
'name' => 'negara_pembuat',
|
||||
'index' => 3,
|
||||
],
|
||||
[
|
||||
'label' => 'Kondisi Mesin',
|
||||
'name' => 'kondisi_mesin',
|
||||
'index' => 4,
|
||||
],
|
||||
];
|
||||
@endphp
|
||||
|
||||
@if (count($inputDataJaminan) > 0)
|
||||
@foreach ($inputDataJaminan as $item)
|
||||
<!-- Nomor Lambung -->
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">{{ $item['label'] }}</label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<input type="text" name="{{ $item['name'] }}" class="input"
|
||||
placeholder="Masukkan {{ $item['label'] }}">
|
||||
|
||||
|
||||
<em id="error-{{ $item['name'] }}" class="alert text-danger text-sm"></em>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
@endforeach
|
||||
@endif
|
||||
|
||||
<div class="flex items-baseline flex-wrap lg:flex-nowrap gap-2.5">
|
||||
<label class="form-label max-w-56">Deskripsi/Keterangan Lain Lain </label>
|
||||
<div class="flex flex-wrap items-baseline w-full">
|
||||
<textarea name="deskripsi" id="" class="textarea"></textarea>
|
||||
@error('deskripsi')
|
||||
<em class="alert text-danger text-sm">{{ $message }}</em>
|
||||
@enderror
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="flex justify-end" style="margin-top: 10px">
|
||||
<button class="btn btn-xs btn-primary" type="button" id="addBagunan">
|
||||
tambah mesin
|
||||
<i class="ki-filled ki-plus"></i>
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -316,9 +316,6 @@
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
function toggleJenisAsset(params) {
|
||||
const inputData = document.querySelector(`input[name="${params}"]:checked`);
|
||||
const luasTanah = document.getElementById('jenis_asset');
|
||||
@@ -347,25 +344,5 @@
|
||||
const selectElement = document.getElementById('selectTidakSesuai');
|
||||
selectElement.style.display = showSelect ? 'block' : 'none';
|
||||
}
|
||||
|
||||
|
||||
const perwakilanContainer = document.getElementById('perwakilan');
|
||||
const addPerwakilanButton = document.getElementById('addPerwakilan');
|
||||
|
||||
// Tambahkan event listener untuk tombol "Tambah"
|
||||
addPerwakilanButton.addEventListener('click', function() {
|
||||
// Clone elemen ".perwakilan"
|
||||
const newDiv = perwakilanContainer.querySelector('.perwakilan').cloneNode(true);
|
||||
|
||||
newDiv.querySelector('input').value = '';
|
||||
const deleteButton = newDiv.querySelector('.delete-button');
|
||||
deleteButton.style.display = 'inline-block';
|
||||
|
||||
deleteButton.addEventListener('click', function() {
|
||||
newDiv.remove();
|
||||
});
|
||||
|
||||
perwakilanContainer.appendChild(newDiv);
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
@endpush
|
||||
|
||||
<div class="w-full grid gap-5 lg:gap-7.5 mx-auto">
|
||||
|
||||
|
||||
|
||||
@include('lpj::component.detail-jaminan',['backLink'=>'surveyor.index'])
|
||||
|
||||
@@ -36,17 +36,17 @@
|
||||
<a href="{{ route('surveyor.show', array_merge(request()->query(), ['id' => $surveyor, 'form' => 'foto'])) }}"
|
||||
class="btn btn-xs {{ request()->has('form') && request('form') == 'foto' ? 'btn-outline btn-primary' : 'btn-light' }}">FOTO</a>
|
||||
|
||||
{{-- <a href="{{ route('surveyor.show', array_merge(request()->query(), ['id' => $surveyor, 'form' => 'data-pembanding'])) }}"
|
||||
<a href="{{ route('surveyor.show', array_merge(request()->query(), ['id' => $surveyor, 'form' => 'data-pembanding'])) }}"
|
||||
class="btn btn-xs {{ request()->has('form') && request('form') == 'data-pembanding' ? 'btn-outline btn-primary' : 'btn-light' }}">DATA
|
||||
PEMBANDING</a> --}}
|
||||
PEMBANDING</a>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="card-body">
|
||||
@if (request()->has('form') && request('form') == 'denah')
|
||||
@include('lpj::surveyor.components.card-tambah')
|
||||
{{-- @elseif(request()->has('form') && request('form') == 'data-pembanding')
|
||||
@include('lpj::surveyor.components.data-pembanding') --}}
|
||||
@elseif(request()->has('form') && request('form') == 'data-pembanding')
|
||||
@include('lpj::surveyor.components.card-tambah')
|
||||
@elseif(request()->has('form') && request('form') == 'foto')
|
||||
@include('lpj::surveyor.components.card-tambah')
|
||||
@else
|
||||
@@ -56,9 +56,7 @@
|
||||
|
||||
<div class="card-footer ">
|
||||
<div class="flex gap-5">
|
||||
<button type="button" id="btnProses" class="btn btn-success">
|
||||
Proses
|
||||
</button>
|
||||
|
||||
<button type="button" id="btnSubmit" class="btn btn-primary">
|
||||
Submit
|
||||
</button>
|
||||
@@ -73,8 +71,6 @@
|
||||
<script>
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
checkButtonStatus();
|
||||
|
||||
document.getElementById('btnProses').addEventListener('click', onProses);
|
||||
document.getElementById('btnSubmit').addEventListener('click', onSubmit);
|
||||
});
|
||||
|
||||
|
||||
@@ -470,7 +470,7 @@ Route::middleware(['auth'])->group(function () {
|
||||
Route::get('inspeksi/{id}/{jaminanId}', [SurveyorController::class, 'formInspeksi'])->name('inspeksi');
|
||||
Route::get('denah/{id}/{jaminanId}', [SurveyorController::class, 'denah'])->name('denah');
|
||||
Route::get('foto/{id}/{jaminanId}', [SurveyorController::class, 'foto'])->name('foto');
|
||||
Route::get('data-pembanding/{id}', [SurveyorController::class, 'dataPembanding'])->name('data-pembanding');
|
||||
Route::get('data-pembanding/{id}/{jaminanId}', [SurveyorController::class, 'dataPembanding'])->name('data-pembanding');
|
||||
Route::get('submitSurveyor/{id}', [SurveyorController::class, 'submitSurveyor'])->name('submitSurveyor');
|
||||
});
|
||||
|
||||
|
||||
Reference in New Issue
Block a user