Class: Alchemy::MissionControl::Jobs::Ability

Inherits:
Object
  • Object
show all
Includes:
CanCan::Ability
Defined in:
lib/alchemy/mission_control/jobs/ability.rb

Instance Method Summary collapse

Constructor Details

#initialize(user) ⇒ Ability



9
10
11
12
13
14
15
16
# File 'lib/alchemy/mission_control/jobs/ability.rb', line 9

def initialize(user)
  @user = user

  if admin?
    can :index, :alchemy_admin_jobs
    can :manage, :admin_jobs
  end
end