Merge branch 'master' of bitbucket.org:code2lab/sxrestaurant

This commit is contained in:
Aung Myo
2018-04-19 10:17:29 +06:30
13 changed files with 32 additions and 11 deletions

View File

@@ -632,6 +632,8 @@ var customer_name = "<%= @customer.name %>";
if (credit <= 0) {
calculate_member_discount(sale_id);
}
$("#pdfModal").modal({show : true, backdrop : false, keyboard : false});
$.ajax({type: "POST",
url: "<%= origami_payment_cash_path %>",
@@ -652,13 +654,14 @@ var customer_name = "<%= @customer.name %>";
var msg = '';
}
$("#loading_wrapper" ).hide();
$("#loading_wrapper" ).hide();
//PDF lightbox data
var pdfPath = "/en/pdfjs/minimal?file=" + result.filename.substring(6);
$("#sale_receipt_no").val(result.receipt_no);
$("#filename").val(result.filename);
$("#printer_name").val(result.printer_name);
$("#receipt_pdf").attr("src", result.filename.substring(6));
$("#receipt_pdf").attr("src", pdfPath);
$("#pdfModal").modal({show : true, backdrop : false, keyboard : false});
$("#pdfModalLabel").text("Sale Completed");
$("#changed_amount").text("");