fix(surveyor): perbaiikan save pembanding kendaraan

This commit is contained in:
majid
2025-03-14 14:30:38 +07:00
parent 05d63fe6eb
commit 3ee55149fa
2 changed files with 14 additions and 15 deletions

View File

@@ -1385,7 +1385,7 @@ class SurveyorController extends Controller
$maxSize = getMaxFileSize('Foto');
$validator = $request->validate([
'permohonan_id' => 'required|exists:permohonan,id',
'type' => 'required|string',
'type' => 'nullable|string',
'dokument_id' => 'required',
'name_foto_objek' => 'nullable|string',
'nomor_registrasi' => 'required|string',

View File

@@ -7,7 +7,7 @@
</a>
@else
<a href="{{ route('surveyor.show', ['id' => $permohonan->id]) }}" class="btn btn-xs btn-info">
<i class="ki-filled ki-exit-left"></i> Kembali
<i class="ki-filled ki-exit-left"></i> Back
</a>
@endif
</div>
@@ -136,11 +136,11 @@
<td class="px-4 py-2">Tahun</td>
<td class="px-4 py-2">
<input type="text" name="tahun" class="input number-format"
<input type="text" name="tahun" class="input "
value="{{ $inspectionData['tahun'] ?? '' }}">
</td>
<td class="px-4 py-2">
<input type="text" name="tahun_pembanding[]" class="input number-format">
<input type="text" name="tahun_pembanding[]" class="input ">
</td>
</tr>
@@ -372,13 +372,13 @@
</tr>
<tr>
<td class="px-4 py-2">Harga</td>
<td class="px-4 py-2">Harga Penawaran/ Transaksi(Rp)</td>
<td class="px-4 py-2">
<input type="text" name="harga" class="input currency"
value="{{ $inspectionData['harga'] ?? '' }}">
<input type="text" name="harga" class="input currency-format"
value="{{ $inspectionData['asset']['harga'] ?? '' }}">
</td>
<td class="px-4 py-2">
<input type="text" name="harga_pembanding[]" class="input currency">
<input type="text" name="harga_pembanding[]" class="input currency-format">
</td>
</tr>
<tr>
@@ -386,7 +386,7 @@
<td class="px-4 py-2">
<div class="input">
<input type="text" name="diskon" class=" currency"
value="{{ $inspectionData['diskon'] ?? '' }}">
value="{{ $inspectionData['asset']['diskon'] ?? '' }}">
<span class="btn btn-icon">
<i class="ki-outline ki-percentage"></i>
</span>
@@ -404,7 +404,7 @@
</td>
</tr>
<tr style="display: none;">
{{-- <tr style="display: none;">
<td class="px-4 py-2">Total</td>
<td class="px-4 py-2">
<input type="text" name="total" class="input currency"
@@ -413,16 +413,15 @@
<td class="px-4 py-2">
<input type="text" name="total_pembanding[]" class="input currency-format">
</td>
</tr>
</tr> --}}
<tr>
<td class="px-4 py-2">Harga Setelah Diskon</td>
<td class="px-4 py-2">
<input type="text" name="harga_diskon" class="input currency-format" readonly
value="{{ $inspectionData['harga_diskon'] ?? '' }}">
<input type="text" name="total" class="input currency-format" readonly
value="{{ $inspectionData['asset']['total'] ?? '' }}">
</td>
<td class="px-4 py-2">
<input type="text" name="harga_diskon_pembanding[]" readonly
class="input currency-format">
<input type="text" name="total_pembanding[]" readonly class="input currency-format">
</td>
</tr>
</tbody>