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
0
Merge Requests
0
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
Boxiang Sun
gitlab-ce
Commits
f51e2183
Commit
f51e2183
authored
Mar 05, 2018
by
Dmitriy Zaporozhets
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Render plugins list on system hooks page
Signed-off-by:
Dmitriy Zaporozhets
<
dmitriy.zaporozhets@gmail.com
>
parent
9c50f96c
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
53 additions
and
53 deletions
+53
-53
app/views/admin/hooks/_form.html.haml
app/views/admin/hooks/_form.html.haml
+20
-22
app/views/admin/hooks/index.html.haml
app/views/admin/hooks/index.html.haml
+30
-28
app/views/shared/plugins/_index.html.haml
app/views/shared/plugins/_index.html.haml
+3
-3
No files found.
app/views/admin/hooks/_form.html.haml
View file @
f51e2183
=
form_errors
(
hook
)
=
form_errors
(
hook
)
.form-group
.form-group
=
form
.
label
:url
,
'URL'
,
class:
'control-label'
=
form
.
label
:url
,
'URL'
,
class:
'label-light'
.col-sm-10
=
form
.
text_field
:url
,
class:
'form-control'
=
form
.
text_field
:url
,
class:
'form-control'
.form-group
.form-group
=
form
.
label
:token
,
'Secret Token'
,
class:
'control-label'
=
form
.
label
:token
,
'Secret Token'
,
class:
'label-light'
.col-sm-10
=
form
.
text_field
:token
,
class:
'form-control'
=
form
.
text_field
:token
,
class:
'form-control'
%p
.help-block
%p
.help-block
Use this token to validate received payloads
Use this token to validate received payloads
.form-group
.form-group
=
form
.
label
:url
,
'Trigger'
,
class:
'control-label'
=
form
.
label
:url
,
'Trigger'
,
class:
'label-light'
.col-sm-10.prepend-top-10
%ul
.list-unstyled
%div
%li
System hook will be triggered on set of events like creating project
.help-block
or adding ssh key. But you can also enable extra triggers like Push events.
System hook will be triggered on set of events like creating project
or adding ssh key. But you can also enable extra triggers like Push events.
.prepend-top-default
.prepend-top-default
=
form
.
check_box
:repository_update_events
,
class:
'pull-left'
=
form
.
check_box
:repository_update_events
,
class:
'pull-left'
...
@@ -24,21 +23,21 @@
...
@@ -24,21 +23,21 @@
%strong
Repository update events
%strong
Repository update events
%p
.light
%p
.light
This URL will be triggered when repository is updated
This URL will be triggered when repository is updated
%
div
%
li
=
form
.
check_box
:push_events
,
class:
'pull-left'
=
form
.
check_box
:push_events
,
class:
'pull-left'
.prepend-left-20
.prepend-left-20
=
form
.
label
:push_events
,
class:
'list-label'
do
=
form
.
label
:push_events
,
class:
'list-label'
do
%strong
Push events
%strong
Push events
%p
.light
%p
.light
This URL will be triggered for each branch updated to the repository
This URL will be triggered for each branch updated to the repository
%
div
%
li
=
form
.
check_box
:tag_push_events
,
class:
'pull-left'
=
form
.
check_box
:tag_push_events
,
class:
'pull-left'
.prepend-left-20
.prepend-left-20
=
form
.
label
:tag_push_events
,
class:
'list-label'
do
=
form
.
label
:tag_push_events
,
class:
'list-label'
do
%strong
Tag push events
%strong
Tag push events
%p
.light
%p
.light
This URL will be triggered when a new tag is pushed to the repository
This URL will be triggered when a new tag is pushed to the repository
%
div
%
li
=
form
.
check_box
:merge_requests_events
,
class:
'pull-left'
=
form
.
check_box
:merge_requests_events
,
class:
'pull-left'
.prepend-left-20
.prepend-left-20
=
form
.
label
:merge_requests_events
,
class:
'list-label'
do
=
form
.
label
:merge_requests_events
,
class:
'list-label'
do
...
@@ -46,9 +45,8 @@
...
@@ -46,9 +45,8 @@
%p
.light
%p
.light
This URL will be triggered when a merge request is created/updated/merged
This URL will be triggered when a merge request is created/updated/merged
.form-group
.form-group
=
form
.
label
:enable_ssl_verification
,
'SSL verification'
,
class:
'control-label checkbox'
=
form
.
label
:enable_ssl_verification
,
'SSL verification'
,
class:
'label-light checkbox'
.col-sm-10
.checkbox
.checkbox
=
form
.
label
:enable_ssl_verification
do
=
form
.
label
:enable_ssl_verification
do
=
form
.
check_box
:enable_ssl_verification
=
form
.
check_box
:enable_ssl_verification
%strong
Enable SSL verification
%strong
Enable SSL verification
app/views/admin/hooks/index.html.haml
View file @
f51e2183
-
page_title
'System Hooks'
-
page_title
'System Hooks'
%h3
.page-title
.row.prepend-top-default
System hooks
.col-lg-4
%h4
.prepend-top-0
=
page_title
%p
#{
link_to
'System hooks '
,
help_page_path
(
'system_hooks/system_hooks'
),
class:
'vlink'
}
can be
used for binding events when GitLab creates a User or Project.
%p
.light
.col-lg-8.append-bottom-default
#{
link_to
'System hooks '
,
help_page_path
(
'system_hooks/system_hooks'
),
class:
'vlink'
}
can be
=
form_for
@hook
,
as: :hook
,
url:
admin_hooks_path
do
|
f
|
used for binding events when GitLab creates a User or Project.
=
render
partial:
'form'
,
locals:
{
form:
f
,
hook:
@hook
}
=
f
.
submit
'Add system hook'
,
class:
'btn btn-create'
%hr
%hr
=
form_for
@hook
,
as: :hook
,
url:
admin_hooks_path
,
html:
{
class:
'form-horizontal'
}
do
|
f
|
-
if
@hooks
.
any?
=
render
partial:
'form'
,
locals:
{
form:
f
,
hook:
@hook
}
.panel.panel-default
.form-actions
.panel-heading
=
f
.
submit
'Add system hook'
,
class:
'btn btn-create'
System hooks (
#{
@hooks
.
count
}
)
%hr
%ul
.content-list
-
@hooks
.
each
do
|
hook
|
%li
.controls
=
render
'shared/web_hooks/test_button'
,
triggers:
SystemHook
.
triggers
,
hook:
hook
,
button_class:
'btn-sm'
=
link_to
'Edit'
,
edit_admin_hook_path
(
hook
),
class:
'btn btn-sm'
=
link_to
'Remove'
,
admin_hook_path
(
hook
),
data:
{
confirm:
'Are you sure?'
},
method: :delete
,
class:
'btn btn-remove btn-sm'
.monospace
=
hook
.
url
%div
-
SystemHook
.
triggers
.
each_value
do
|
event
|
-
if
hook
.
public_send
(
event
)
%span
.label.label-gray
=
event
.
to_s
.
titleize
%span
.label.label-gray
SSL Verification:
#{
hook
.
enable_ssl_verification
?
'enabled'
:
'disabled'
}
-
if
@hooks
.
any?
=
render
'shared/plugins/index'
.panel.panel-default
.panel-heading
System hooks (
#{
@hooks
.
count
}
)
%ul
.content-list
-
@hooks
.
each
do
|
hook
|
%li
.controls
=
render
'shared/web_hooks/test_button'
,
triggers:
SystemHook
.
triggers
,
hook:
hook
,
button_class:
'btn-sm'
=
link_to
'Edit'
,
edit_admin_hook_path
(
hook
),
class:
'btn btn-sm'
=
link_to
'Remove'
,
admin_hook_path
(
hook
),
data:
{
confirm:
'Are you sure?'
},
method: :delete
,
class:
'btn btn-remove btn-sm'
.monospace
=
hook
.
url
%div
-
SystemHook
.
triggers
.
each_value
do
|
event
|
-
if
hook
.
public_send
(
event
)
%span
.label.label-gray
=
event
.
to_s
.
titleize
%span
.label.label-gray
SSL Verification:
#{
hook
.
enable_ssl_verification
?
'enabled'
:
'disabled'
}
app/views/shared/plugins/_index.html.haml
View file @
f51e2183
...
@@ -13,8 +13,8 @@
...
@@ -13,8 +13,8 @@
%ul
.content-list
%ul
.content-list
-
plugins
.
each
do
|
file
|
-
plugins
.
each
do
|
file
|
%li
%li
%span
.titl
e
=
boolean_to_icon
tru
e
=
File
.
basename
(
file
)
=
File
.
basename
(
file
)
-
else
-
else
%p
.
settings-message.text-center.append-bottom-0
%p
.
light-well.text-center
No plugins found.
No plugins found.
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