add jenis bayaran at history ansuran

This commit is contained in:
Afrina Alimi
2024-01-14 12:39:09 +08:00
parent 8d18626410
commit 1b496fe850
2 changed files with 18 additions and 8 deletions
+15 -6
View File
@@ -1402,14 +1402,23 @@
$.each(data,function(index,bayaran){
var urlroute = '{{ route("resit.ansuran", ":id") }}';
var bayaranteller;
if(bayaran['teller'] != 'Online')
bayaranteller = 'KT';
if(bayaran['teller'] == 'Online')
bayaranteller = 'ON';
urlroute = urlroute.replace(':id', bayaran['id']);
historybayarandatatable.row.add([
counter,
bayaran['created_at'],
"RM " + bayaran['duit_masuk'],
'<a class="btn btn-info" target="_blank" href='+ urlroute +'>Cetak</a>'
]).draw();
counter = counter + 1;
counter,
bayaran['created_at'],
"RM " + bayaran['duit_masuk'],
bayaranteller,
'<a class="btn btn-info" target="_blank" href='+ urlroute +'>Cetak</a>'
]).draw();
counter = counter + 1;
});
}