Skip to content

Commit

Permalink
grant manage roles for users
Browse files Browse the repository at this point in the history
  • Loading branch information
carrickr committed May 15, 2017
1 parent 43594b4 commit 2759f9c
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions app/models/concerns/hyrax/ability.rb
Original file line number Diff line number Diff line change
Expand Up @@ -131,6 +131,9 @@ def feature_abilities

def admin_set_abilities
can :manage, [AdminSet, Hyrax::PermissionTemplate, Hyrax::PermissionTemplateAccess] if admin?
can :manage, AdminSet do |adminset|
admin_set_ids_for_management.include?(adminset.id)
end

can [:create, :edit, :update, :destroy], Hyrax::PermissionTemplate do |template|
test_edit(template.admin_set_id)
Expand Down

0 comments on commit 2759f9c

Please sign in to comment.