update surat notis peirngatan dan info pelanggan

This commit is contained in:
Nur Izzati Zulkifli
2024-01-24 14:45:25 +08:00
parent 8f5e88ea7e
commit d6159e12f3
6 changed files with 591 additions and 52 deletions
+10 -20
View File
@@ -205,6 +205,7 @@
<th>Jum Tuntut/Bayar</th>
<th>Keuntungan</th>
<th>Caj Lelong</th>
<th>Dituntut Oleh</th>
</tr>
</thead>
</table>
@@ -802,23 +803,13 @@
var urlroute = '{{ route("lelongan", ":id") }}';
urlroute = urlroute.replace(':id', gadai_detail["norujukan"]);
var tuntutan = 'Pelanggan';
$.ajax({
method:"GET",
async:false,
url: api_url + "/api/check/customer/",
data:{
"norujukan" : gadai_detail['norujukan'],
"kodcaw" : kodcaw
},
success: function(response){
if(response[0].teller == 'DM')
{
tuntutan = 'WTD';
}
}
});
var tuntutan = '';
if(gadai_detail['datatuntut']['teller'] == 'DM')
{
tuntutan = 'WTD';
}else{
tuntutan = 'Pelanggan';
}
if(gadai_detail['trkhtuntut'] == null){
tablelelong.row.add([
@@ -837,7 +828,7 @@
}else{
tablelelong.row.add([
counter,
'<a href="#" onclick="checktuntutbaki(this)" data-norujukan=' + gadai_detail['norujukan'] + ' data-tarikhtuntut=' + gadai_detail['trkhtuntut'] + '>' + gadai_detail['norujukan'] + '</a>',
gadai_detail['norujukan'],
gadai_detail['t_lelong'],
gadai_detail['trkhtuntut'],
'RM '+ formatter.format(gadai_detail['pinjaman']),
@@ -845,8 +836,7 @@
'RM '+formatter.format(gadai_detail['baki']),
'RM '+formatter.format(gadai_detail['bakiupah']),
'RM '+formatter.format(gadai_detail['cajlelong']),
tuntutan,
'<button class="btn btn-info" onclick="cetaktuntutbaki(this)" data-norujukan=' + gadai_detail['norujukan'] +'>Cetak</button>'
tuntutan
]).draw();
}
}