edit for shop_code query

This commit is contained in:
Thein Lin Kyaw
2020-01-13 15:28:26 +06:30
parent bad46cf02c
commit d379c05298
32 changed files with 58 additions and 115 deletions

View File

@@ -62,13 +62,13 @@ class Api::OrdersController < Api::ApiController
def create
Rails.logger.debug "Order Source - " + params[:order_source].to_s
Rails.logger.debug "Table ID - " + params[:table_id].to_s
@shop = Shop.find_by_shop_code(params[:shop_code])
current_shift = ShiftSale.current_shift
if current_shift.nil?
@status = false
@message = "No Current Open Shift for This Employee"
else
current_user =Employee.find(current_shift.employee_id)
current_user = Employee.find(current_shift.employee_id)
if checkin_checkout_time(params[:booking_id])
table = DiningFacility.find(params[:table_id]) if params[:table_id].present?