Commit graph

10 commits

Author SHA1 Message Date
GitLab Bot
0ae8428c8e Add latest changes from gitlab-org/gitlab@master 2021-05-11 21:10:21 +00:00
GitLab Bot
b7dfe2ae40 Add latest changes from gitlab-org/gitlab@master 2019-09-13 13:26:31 +00:00
gfyoung
fbde835404 Enable more frozen string in app/services/**/*.rb
Partially addresses #47424.
2018-07-17 15:19:40 -07:00
Rémy Coutable
1c88d92b3f Improve Member services
Signed-off-by: Rémy Coutable <remy@rymai.me>
2018-02-27 16:02:22 +01:00
Rémy Coutable
bf41063679 Remove explicit audit event log in MembershipActions
Move it to Members::ApproveAccessRequestService.

Also, note that there was a double audit event log for access request
destruction.

Signed-off-by: Rémy Coutable <remy@rymai.me>
2018-02-27 16:02:22 +01:00
TM Lee
2cf3fc18a6 Refactor member view by using presenter
- Create MemberPresenter alongside with GroupMemberPresenter and ProjectMemberPresenter
- Make Member model Presentable
- Move action_member_permission from MembersHelper into the MemberPresenter
- Added rspec using double, separate specs for GroupMemberPresenter and ProjectMemberPresenter

Fixes #28004.

Signed-off-by: Rémy Coutable <remy@rymai.me>
2017-12-11 18:30:56 +01:00
Rémy Coutable
61e2b88dd1
Allow Members::ApproveAccessRequestService to accept a new :force param
This param allows to bypass permission check. It is useful for LDAP-sync
where even owners don't have the :admin_group_member permission.

See
6081c37123/app/policies/group_policy.rb (L38)
and https://gitlab.com/gitlab-org/gitlab-ee/issues/1159

Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-10-28 15:45:26 +02:00
Rémy Coutable
94996963c5 Inverse condition in Members::ApproveAccessRequestService
Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-09-22 15:50:48 +02:00
Rémy Coutable
5dcdf1d51b Ensure Members::ApproveAccessRequestService can fin a requester by ID
Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-09-22 15:50:48 +02:00
Rémy Coutable
b3f0a82f50 New Members::ApproveAccessRequestService
Signed-off-by: Rémy Coutable <remy@rymai.me>
2016-09-22 15:50:47 +02:00