debian-mirror-gitlab/app/serializers/group_link/project_group_link_entity.rb
2021-03-11 19:13:27 +05:30

22 lines
468 B
Ruby

# frozen_string_literal: true
module GroupLink
class ProjectGroupLinkEntity < GroupLink::GroupLinkEntity
include RequestAwareEntity
include Projects::ProjectMembersHelper
expose :can_update do |group_link|
can_manage_project_members?(group_link.project)
end
expose :can_remove do |group_link|
can_manage_project_members?(group_link.project)
end
private
def current_user
options[:current_user]
end
end
end