perbaikan diskon data pembanding, luas tanah, bangunan, apartement di form inspeksi

This commit is contained in:
majid
2025-01-06 16:30:11 +07:00
parent a74f3a1865
commit fcc53a7111
5 changed files with 55 additions and 35 deletions

View File

@@ -13,9 +13,16 @@
@if (isset($permohonan->debiture->documents))
@foreach ($permohonan->debiture->documents as $item)
@php
$luas = $item->detail;
$details = json_decode($luas[0]->details, true);
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
$luas_tanah = 'N/A';
if ($item->detail) {
foreach ($item->detail as $luas) {
if (isset($luas->name) && $luas->name === 'Sertifikat') {
$details = json_decode($luas->details, true);
$luas_tanah = isset($details['luas_tanah']) ? $details['luas_tanah'] : 'N/A';
break;
}
}
}
@endphp
<input type="hidden" name="luas_tanah_sesuai" class="input" value="{{ $luas_tanah }}">
<p class="text-2sm text-gray-700">{{ $luas_tanah }} m<sup>2</sup></p>