diff --git a/app/controllers/crm/home_controller.rb b/app/controllers/crm/home_controller.rb index 6866ddf1..d3934eef 100644 --- a/app/controllers/crm/home_controller.rb +++ b/app/controllers/crm/home_controller.rb @@ -1,12 +1,12 @@ class Crm::HomeController < BaseCrmController def index - # @booking = Booking.all - # @customer = Customer.all - # from = Time.now.beginning_of_day.utc - # to = Time.now.end_of_day.utc - # @queue = DiningQueue.where('created_at BETWEEN ? AND ?', from, to).order('queue_no ASC') - redirect_to crm_customers_path + @booking = Booking.all + @customer = Customer.all + from = Time.now.beginning_of_day.utc + to = Time.now.end_of_day.utc + @queue = DiningQueue.where('created_at BETWEEN ? AND ?', from, to).order('queue_no ASC') + # redirect_to crm_customers_path # .where("dining_facilities.is_active=? and orders.date between ? and ?",true,from,to) end diff --git a/app/controllers/origami/shifts_controller.rb b/app/controllers/origami/shifts_controller.rb index e527da46..2d005cfb 100644 --- a/app/controllers/origami/shifts_controller.rb +++ b/app/controllers/origami/shifts_controller.rb @@ -39,8 +39,12 @@ class Origami::ShiftsController < BaseOrigamiController printer.print_close_cashier(print_settings,@shift,shop_details) + end + session[:session_token] = nil + redirect_to root_path + end def edit diff --git a/app/models/ability.rb b/app/models/ability.rb index 3e5fc8b6..f2c8c0f0 100644 --- a/app/models/ability.rb +++ b/app/models/ability.rb @@ -100,6 +100,8 @@ class Ability can :show, :payment can :create, :payment can :reprint, :payment + + can :manage, DiningQueue elsif user.role == "accountant"