update
This commit is contained in:
@@ -223,6 +223,7 @@
|
||||
<th>Nama Rack</th>
|
||||
<th>Tgl Simpan</th>
|
||||
<th>Input By</th>
|
||||
<th>Aksi</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tfoot>
|
||||
@@ -240,6 +241,7 @@
|
||||
<th>Nama Rack</th>
|
||||
<th>Tgl Simpan</th>
|
||||
<th>Input By</th>
|
||||
<th></th>
|
||||
</tr>
|
||||
</tfoot>
|
||||
<tbody>
|
||||
@@ -258,6 +260,12 @@
|
||||
<td>{{ $row->rack->name ?? '-' }}</td>
|
||||
<td>{{ $row->stored_at }}</td>
|
||||
<td>{{ $row->input_by }}</td>
|
||||
<td class="text-center">
|
||||
<form method="POST" action="{{ route('biorepository.deleteSpecimen', $row->id) }}" class="d-inline js-delete-specimen">
|
||||
@csrf
|
||||
<button type="submit" class="btn btn-sm btn-danger">Hapus</button>
|
||||
</form>
|
||||
</td>
|
||||
</tr>
|
||||
@endforeach
|
||||
</tbody>
|
||||
@@ -478,7 +486,11 @@
|
||||
$(function () {
|
||||
$('#biorepoTable tfoot th').each(function () {
|
||||
var title = $(this).text();
|
||||
$(this).html('<input type="text" placeholder="Filter ' + title + '" />');
|
||||
if (title !== '') {
|
||||
$(this).html('<input type="text" placeholder="Filter ' + title + '" />');
|
||||
} else {
|
||||
$(this).html('');
|
||||
}
|
||||
});
|
||||
|
||||
var table = $('#biorepoTable').DataTable({
|
||||
@@ -498,6 +510,12 @@
|
||||
$('#btnOpenListTab').on('click', function () {
|
||||
$('#tabListLink').tab('show');
|
||||
});
|
||||
|
||||
$(document).on('submit', '.js-delete-specimen', function (e) {
|
||||
if (!confirm('Yakin hapus spesimen ini?')) {
|
||||
e.preventDefault();
|
||||
}
|
||||
});
|
||||
});
|
||||
</script>
|
||||
@endpush
|
||||
Reference in New Issue
Block a user