Refactor AJAX requests from Request.JSONF to Request_JSF across multiple scripts for consistency and improved functionality.

This commit is contained in:
2026-11-01 13:11:40 +07:00
parent 52897c25c5
commit 7a585ab7c2
58 changed files with 200 additions and 200 deletions
+6 -6
View File
@@ -180,7 +180,7 @@ var MutasiJS = {
detail_hapus: function(acell){
FoniaJS.showConfirm('Konfirmasi', 'Hapus item <strong>"'+acell[5]+'"</strong> ?', () => {
new Request.JSONF({
new Request_JSF({
url: this.PHP + '/table_detail',
sendParam: ['mode','mode_detail=delete','No_Mutasi','ID='+acell[0]],
onSuccess: () => $('#Nama_Produk').focus()
@@ -189,7 +189,7 @@ var MutasiJS = {
},
detail_simpan: function(){
new Request.JSONF({
new Request_JSF({
url: this.PHP + '/table_detail',
sendParam: ['mode','mode_detail','No_Mutasi','ID','InvID','SatuanID','VarianID','Qty','Harga_Beli','Dari_CabID','Ke_CabID'],
onSuccess: () => {
@@ -249,18 +249,18 @@ var MutasiJS = {
}
}).send();
} else if (tipe=="tabel-detail"){
new Request.JSONF({
new Request_JSF({
url: this.PHP + '/table_detail',
sendParam: ['mode','No_Mutasi']
}).send();
} else if (tipe=="brow-tx"){
new Request.JSONF({
new Request_JSF({
url: this.PHP + '/brow_tx',
sendParam: ['Cari_TX'],
onSuccess: () => FoniaJS.setFocus('#Cari_TX')
}).send();
} else if (tipe=="brow-produk"){
new Request.JSONF({
new Request_JSF({
url: this.PHP + '/brow_produk',
sendParam: ['Cari_Produk','Dari_CabID'],
onSuccess: () => FoniaJS.setFocus('#Cari_Produk')
@@ -276,7 +276,7 @@ var MutasiJS = {
var _qty = FoniaJS.StrToFloat($('#POS_Qty').val());
var adata = item.data.split(':');
// Satuan : Varian : Harga_Pokok
new Request.JSONF({
new Request_JSF({
url: MutasiJS.PHP + '/table_detail',
sendParam: ['mode','mode_detail=insert','No_Mutasi','InvID='+item.value,'SatuanID='+adata[0],'VarianID='+adata[1],'Qty='+_qty,'Harga_Beli='+adata[2]],
onSuccess: () => $('#POS_Qty').val('1.00')