update waste and spoilage

This commit is contained in:
Aung Myo
2018-03-30 14:20:47 +06:30
parent 15f0abac21
commit 5588f40753
16 changed files with 380 additions and 39 deletions

View File

@@ -598,8 +598,6 @@
</div>
</div>
<div class="modal-footer ">
</div>
</div>
</div>
@@ -1059,8 +1057,6 @@
if (isConfirm) {
var sale_id = "<%= @obj_sale.sale_id rescue "" %>"
var url = "/origami/sale/" + sale_id + '/cashier/waste_and_spoilage';
console.log(url)
$.ajax({
type: 'POST',
url: url,
@@ -1068,10 +1064,10 @@ console.log(url)
success: function (result) {
console.log(result)
// For Server Print - from jade
// if ($("#server_mode").val() == "cloud") {
// code2lab.printFile(result.filepath.substr(6), result.printer_url);
// }
// window.location.href = '/origami/';
if ($("#server_mode").val() == "cloud") {
code2lab.printFile(result.filepath.substr(6), result.printer_url);
}
window.location.href = '/origami/';
}
});
}