added pengguna,kurir page, with socket.io,need to switch this to node.js first

This commit is contained in:
kicap1992
2025-05-16 11:43:38 +08:00
parent 5329fb8265
commit 0ba4e846dc
1095 changed files with 12336 additions and 35 deletions

View File

@ -116,9 +116,13 @@
<button type="button" class="btn btn-sm btn-info btn-rounded waves-effect waves-light"
onclick="addKurirOpenModal()">Pendaftaran Kurir Baru</button>
</div>
<table id="tb-kurir" class="table table-striped table-bordered display" style="width:100%">
<div class="form-group" style="overflow-x: auto;">
<table id="tb-kurir" class="table table-striped table-bordered display"
style="width:100%">
</table>
</div>
</table>
</div>
</div>
@ -253,7 +257,8 @@
// destroy table
// $('#tb-kurir').DataTable().destroy();
$('#tb-kurir').DataTable({
responsive: true,
// responsive: true,
scrollX: true,
// order: [
// [0, 'asc']
// ],
@ -282,6 +287,13 @@
return data
}
},
{
"mData": "status",
"title": "Status",
"render": function (data, type, row) {
return data == null || data == "" || data == undefined ? "Tersedia" : data
}
},
{
"mData": null,
"title": "Aksi",
@ -443,7 +455,7 @@
$("#btn-update-kurir").hide()
$('#modal-kurir').modal('show')
var img = document.createElement('img');
img.src = 'kurir/gambar/' + data.no_telpon + '/'+ data.gambar_kurir;
img.src = 'kurir/gambar/' + data.no_telpon + '/' + data.gambar_kurir;
img.style.maxWidth = '100%'; // Make the image fit the width of the div
img.style.maxHeight = '100%'; // Make the image fit the height of the div
@ -457,7 +469,7 @@
previewDiv.appendChild(img);
var img = document.createElement('img');
img.src = 'kurir/gambar/' + data.no_telpon + '/'+ data.gambar_motor;
img.src = 'kurir/gambar/' + data.no_telpon + '/' + data.gambar_motor;
img.style.maxWidth = '100%'; // Make the image fit the width of the div
img.style.maxHeight = '100%'; // Make the image fit the height of the div