edit login
This commit is contained in:
@@ -2,7 +2,7 @@ class HomeController < ApplicationController
|
||||
skip_before_action :authenticate, only: [:index, :show, :create, :update, :destroy]
|
||||
|
||||
def index
|
||||
@employees = Employee.all.order("name asc")
|
||||
@employees = Employee.all_emp_except_waiter.order("name asc")
|
||||
@login_form = LoginForm.new()
|
||||
end
|
||||
|
||||
@@ -19,6 +19,8 @@ class HomeController < ApplicationController
|
||||
|
||||
if @employee != nil
|
||||
session[:session_token] = @employee.token_session
|
||||
#if cashier => already opening cahshier?
|
||||
|
||||
redirect_to origami_root_path
|
||||
else
|
||||
render :show, flash[:notice] => "Invalid PIN for Employee. Please try again!"
|
||||
|
||||
Reference in New Issue
Block a user