revised form up country (again)
This commit is contained in:
@@ -91,9 +91,6 @@
|
||||
<th>Jarak</th>
|
||||
<th>Total</th>
|
||||
<th>Total Approved</th>
|
||||
<th>Bukti 1</th>
|
||||
<th>Bukti 2</th>
|
||||
<th>Bukti 3</th>
|
||||
<th>Account Number</th>
|
||||
<th>Status</th>
|
||||
@if (auth()->user()->can('approval.approve'))
|
||||
@@ -125,33 +122,6 @@
|
||||
-
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if ($item->bukti1)
|
||||
<a href="{{ NextCloudHelper::getFileUrl($item->bukti1) }}">
|
||||
Download
|
||||
</a>
|
||||
@else
|
||||
-
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if ($item->bukti2)
|
||||
<a href="{{ NextCloudHelper::getFileUrl($item->bukti2) }}">
|
||||
Download
|
||||
</a>
|
||||
@else
|
||||
-
|
||||
@endif
|
||||
</td>
|
||||
<td>
|
||||
@if ($item->bukti3)
|
||||
<a href="{{ NextCloudHelper::getFileUrl($item->bukti3) }}">
|
||||
Download
|
||||
</a>
|
||||
@else
|
||||
-
|
||||
@endif
|
||||
</td>
|
||||
<td>{{ $item->account_number }}</td>
|
||||
<td>
|
||||
@if ($item->status == 'On Progress')
|
||||
@@ -168,8 +138,8 @@
|
||||
@if ($item->status == 'On Progress')
|
||||
<form action="javascript:void(0);" class="d-inline">
|
||||
<button type="button"
|
||||
class="btn btn-success btn-sm open-approve-modal"
|
||||
data-id="{{ route('forms.up-country.approve', $item->id) }}">
|
||||
class="btn btn-success btn-sm open-approve-modal"
|
||||
data-id="{{ route('forms.up-country.approve', $item->id) }}">
|
||||
Approve
|
||||
</button>
|
||||
</form>
|
||||
@@ -294,13 +264,16 @@
|
||||
<strong>Jarak:</strong> <span id="jarak"></span>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<strong>Bukti 1:</strong> <span id="bukti1"></span>
|
||||
<strong>Bukti Allowance:</strong> <span id="bukti_allowance"></span>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<strong>Bukti 2:</strong> <span id="bukti2"></span>
|
||||
<strong>Bukti Transport Dalam Kota:</strong> <span id="bukti_transport_dalkot"></span>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<strong>Bukti 3:</strong> <span id="bukti3"></span>
|
||||
<strong>Bukti Transport Antar Kota:</strong> <span id="bukti_transport_ankot"></span>
|
||||
</li>
|
||||
<li class="list-group-item">
|
||||
<strong>Bukti Hotel:</strong> <span id="bukti_hotel"></span>
|
||||
</li>
|
||||
</ul>
|
||||
<p class="mt-2">Please select the items you want to approve:</p>
|
||||
@@ -381,6 +354,7 @@
|
||||
$('#modalContent').addClass('d-none');
|
||||
|
||||
$('#approveForm').attr('action', approveUrl); // Set the form action
|
||||
$('#loadingSpinner').addClass('d-flex');
|
||||
$('#approveModal').modal('show'); // Show the modal
|
||||
|
||||
// Get detail from /forms/up-country/detail/{id}
|
||||
@@ -413,9 +387,11 @@
|
||||
}));
|
||||
$('#tujuan').text(data.tujuan);
|
||||
$('#jarak').text(data.jarak + ' km');
|
||||
$('#bukti1').html(data.bukti1 ? '<a href="' + data.bukti1 + '" target="_blank">Download</a>' : '-');
|
||||
$('#bukti2').html(data.bukti2 ? '<a href="' + data.bukti2 + '" target="_blank">Download</a>' : '-');
|
||||
$('#bukti3').html(data.bukti3 ? '<a href="' + data.bukti3 + '" target="_blank">Download</a>' : '-');
|
||||
|
||||
$('#bukti_allowance').html(data.bukti_allowance ? '<a href="' + data.bukti_allowance + '" target="_blank">Download</a>' : '-');
|
||||
$('#bukti_transport_dalkot').html(data.bukti_transport_dalkot ? '<a href="' + data.bukti_transport_dalkot + '" target="_blank">Download</a>' : '-');
|
||||
$('#bukti_transport_ankot').html(data.bukti_transport_ankot ? '<a href="' + data.bukti_transport_ankot + '" target="_blank">Download</a>' : '-');
|
||||
$('#bukti_hotel').html(data.bukti_hotel ? '<a href="' + data.bukti_hotel + '" target="_blank">Download</a>' : '-');
|
||||
|
||||
// Hide spinner and show content
|
||||
$('#loadingSpinner').hide();
|
||||
|
||||
Reference in New Issue
Block a user