move table & order item actioncable added
This commit is contained in:
@@ -13,7 +13,19 @@ class Printer::OrderQueuePrinter < Printer::PrinterWorker
|
||||
# check for item not to show
|
||||
# if order_item[0].price != 0
|
||||
pdf = print_settings.unique_code.constantize.new(print_settings,order_item[0], print_status, options, oqs.use_alternate_name, before_updated_qty)
|
||||
booking_id = Booking.get_booking_id(order_id)
|
||||
# end
|
||||
ActionCable.server.broadcast("print_channel",
|
||||
queue: oqs.station_name,
|
||||
unique_code: print_settings.unique_code,
|
||||
print_copies: print_settings.print_copies,
|
||||
data: {
|
||||
order_item: order_item[0].as_json(methods: :type),
|
||||
print_status: print_status.gsub(/[()]/, ""),
|
||||
booking_id: booking_id,
|
||||
precision: print_settings.precision
|
||||
}
|
||||
)
|
||||
|
||||
shop = Shop.current_shop
|
||||
directory_name = 'public/orders_'+shop.shop_code
|
||||
|
||||
@@ -211,6 +211,21 @@ class Printer::ReceiptPrinter < Printer::PrinterWorker
|
||||
#no print in cloud server
|
||||
self.print("tmp/print_move_table.pdf", oqs.printer_name)
|
||||
end
|
||||
ActionCable.server.broadcast("print_channel",
|
||||
queue: oqs.station_name,
|
||||
unique_code: print_settings.unique_code,
|
||||
print_copies: print_settings.print_copies,
|
||||
data: {
|
||||
type: type,
|
||||
body: {
|
||||
to: to,
|
||||
from: from,
|
||||
date: date,
|
||||
moved_by: moved_by,
|
||||
order_items: order_items.as_json,
|
||||
},
|
||||
}
|
||||
)
|
||||
end
|
||||
|
||||
#Bill Receipt Print
|
||||
|
||||
Reference in New Issue
Block a user