fix(surveyor): tambah nama desa dan ganti n/a ke angak 0

This commit is contained in:
majid
2025-02-13 13:21:02 +07:00
parent 51bc603fe7
commit 90249b83e1
4 changed files with 5 additions and 29 deletions

View File

@@ -13,12 +13,12 @@
@if (isset($permohonan->documents))
@foreach ($permohonan->documents as $item)
@php
$luas_tanah = 'N/A';
$luas_tanah = 0;
if ($item->detail) {
foreach ($item->detail as $luas) {
if (isset($luas->name) && $luas->jenis_legalitas_jaminan_id === 1) {
$details = json_decode($luas->details, true);
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 0;
break;
}
}