End of day commit
This commit is contained in:
@@ -0,0 +1,11 @@
|
||||
class Ability
|
||||
include CanCan::Ability
|
||||
def initialize(settings)
|
||||
settings ||= SupplierEmployeesSettings.new(Supplier.new).for_employee(nil)
|
||||
if settings.manager?
|
||||
can :manage, :all
|
||||
else
|
||||
can :read, :all
|
||||
end
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user