check shift
This commit is contained in:
@@ -82,7 +82,7 @@ class Sale < ApplicationRecord
|
||||
self.tax_type = "exclusive"
|
||||
|
||||
# set cashier
|
||||
if order_source = "emenu"
|
||||
if order_source.downcase == "emenu"
|
||||
table = DiningFacility.find(booking.dining_facility_id)
|
||||
cashier_zone = CashierTerminalByZone.find_by_zone_id(table.zone_id)
|
||||
shift = ShiftSale.where("shift_started_at is not null and shift_closed_at is null and cashier_terminal_id = #{cashier_zone.cashier_terminal_id}").first
|
||||
|
||||
Reference in New Issue
Block a user