Refactor printing logic across multiple scripts to use method chaining for improved readability and consistency
- Updated Printer and PrinterPos instantiation to use method chaining with addParam instead of add_param. - Refactored print functions in various modules including opname.js, pos.js, tukar.js, ppobtx.js, prabayar.js, and multiple report scripts. - Enhanced code clarity and maintainability by standardizing parameter addition for print jobs.
This commit is contained in:
@@ -35,11 +35,11 @@ var PrabayarJS = {
|
||||
},
|
||||
|
||||
proses_print(oc, no_cetak) {
|
||||
var cetak = new PrinterPos('apps/php/repo/nota.php');
|
||||
cetak.add_param("data", "ppob-pos");
|
||||
cetak.add_param("Nomor_Cetak", no_cetak);
|
||||
cetak.add_param("Open_Cash", oc);
|
||||
cetak.exec();
|
||||
new PrinterPos('apps/php/repo/nota.php')
|
||||
.addParam("data", "ppob-pos")
|
||||
.addParam("Nomor_Cetak", no_cetak)
|
||||
.addParam("Open_Cash", oc)
|
||||
.exec();
|
||||
},
|
||||
|
||||
proses_delete() {
|
||||
|
||||
Reference in New Issue
Block a user