shop code

This commit is contained in:
Myat Zin Wai Maw
2019-11-22 18:24:02 +06:30
parent 5a3f328789
commit d1ab2c194d
106 changed files with 834 additions and 895 deletions

View File

@@ -195,7 +195,7 @@ class Printer::ReceiptPrinter < Printer::PrinterWorker
if !printer_settings.nil?
if !printer_settings.unique_code.strip.downcase.include? ("receiptbillorder")
pdf = ReceiptBillPdf.new(printer_settings, kbz_pay_status, qr_code, sale_items, sale_data, customer_name, item_price_by_accounts, discount_price_by_accounts, member_info,rebate_amount,shop_details,printed_status,balance,card_data,other_amount,latest_order_no,card_balance_amount)
settings = PrintSetting.all
settings = PrintSetting.where("shop_code='#{shop_details.shop_code}'")
if !settings.nil?
settings.each do |setting|
if setting.unique_code == 'ReceiptBillPdf'
@@ -206,7 +206,7 @@ class Printer::ReceiptPrinter < Printer::PrinterWorker
end
end
receipt_bill_a5_pdf = Lookup.collection_of("print_settings") #print_settings with name:ReceiptBillA5Pdf
receipt_bill_a5_pdf = Lookup.where("shop_code='#{shop_details.shop_code}'").collection_of("print_settings") #print_settings with name:ReceiptBillA5Pdf
if !receipt_bill_a5_pdf.empty?
receipt_bill_a5_pdf.each do |receipt_bilA5|
if receipt_bilA5[0] == 'ReceiptBillA5Pdf'