Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
1
Merge Requests
1
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
nexedi
gitlab-ce
Commits
08fda6a2
Commit
08fda6a2
authored
Aug 14, 2014
by
Jan-Willem van der Meer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add missing ldap_group_links controller
parent
c5f08ad3
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
32 additions
and
0 deletions
+32
-0
app/controllers/groups/ldap_group_links_controller.rb
app/controllers/groups/ldap_group_links_controller.rb
+32
-0
No files found.
app/controllers/groups/ldap_group_links_controller.rb
0 → 100644
View file @
08fda6a2
class
Groups::LdapGroupLinksController
<
ApplicationController
before_action
:group
before_action
:authorize_admin_group!
def
create
ldap_group_link
=
@group
.
ldap_group_links
.
build
(
ldap_group_link_params
)
if
ldap_group_link
.
save
redirect_to
:back
,
notice:
'New LDAP link saved'
else
redirect_to
:back
,
alert:
'Could not create new LDAP link'
end
end
def
destroy
@group
.
ldap_group_links
.
where
(
id:
params
[
:id
]).
destroy_all
redirect_to
:back
,
notice:
'LDAP link removed'
end
private
def
group
@group
||=
Group
.
find_by
(
path:
params
[
:group_id
])
end
def
authorize_admin_group!
render_404
unless
can?
(
current_user
,
:manage_group
,
group
)
end
def
ldap_group_link_params
params
.
require
(
:ldap_group_link
).
permit
(
:cn
,
:group_access
)
end
end
\ No newline at end of file
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment