demarches-normaliennes/app/controllers/admins_group_managers/admins_groups_controller.rb
2023-10-03 13:51:57 +02:00

14 lines
332 B
Ruby

module AdminsGroupManagers
class AdminsGroupsController < AdminsGroupManagerController
def index
@admins_groups = admins_groups
end
private
def admins_groups
admins_group_ids = current_admins_group_manager.admins_group_ids
AdminsGroup.where(id: admins_group_ids.compact.uniq)
end
end
end