2013-10-08 05:06:46 -04:00
|
|
|
%h3.page-title
|
|
|
|
System Hooks
|
|
|
|
|
|
|
|
%p.light
|
|
|
|
#{link_to "System hooks ", help_system_hooks_path, class: "vlink"} can be
|
|
|
|
used for binding events when GitLab creates a User or Project.
|
|
|
|
|
|
|
|
%hr
|
|
|
|
|
2012-07-12 15:10:34 -04:00
|
|
|
|
2012-08-23 17:04:43 -04:00
|
|
|
= form_for @hook, as: :hook, url: admin_hooks_path, html: { class: 'form-inline' } do |f|
|
2012-07-12 15:10:34 -04:00
|
|
|
-if @hook.errors.any?
|
2013-01-30 09:53:18 -05:00
|
|
|
.alert.alert-error
|
2012-07-12 15:10:34 -04:00
|
|
|
- @hook.errors.full_messages.each do |msg|
|
|
|
|
%p= msg
|
2013-08-07 16:20:10 -04:00
|
|
|
.control-group
|
2012-07-12 15:10:34 -04:00
|
|
|
= f.label :url, "URL:"
|
2013-08-07 16:20:10 -04:00
|
|
|
.controls
|
2013-08-08 04:57:34 -04:00
|
|
|
= f.text_field :url, class: "text_field input-xxlarge input-xpadding"
|
2012-07-12 15:10:34 -04:00
|
|
|
|
2013-04-18 10:28:09 -04:00
|
|
|
= f.submit "Add System Hook", class: "btn btn-create"
|
2012-07-12 15:10:34 -04:00
|
|
|
%hr
|
|
|
|
|
|
|
|
-if @hooks.any?
|
|
|
|
%h3
|
|
|
|
Hooks
|
|
|
|
%small (#{@hooks.count})
|
|
|
|
%br
|
2012-09-03 14:53:16 -04:00
|
|
|
%table
|
2012-07-12 15:10:34 -04:00
|
|
|
%tr
|
|
|
|
%th URL
|
|
|
|
%th Method
|
|
|
|
%th
|
|
|
|
- @hooks.each do |hook|
|
|
|
|
%tr
|
|
|
|
%td
|
|
|
|
= link_to admin_hook_path(hook) do
|
|
|
|
%strong= hook.url
|
2013-01-30 09:40:43 -05:00
|
|
|
= link_to 'Test Hook', admin_hook_test_path(hook), class: "btn btn-small pull-right"
|
2012-07-12 15:10:34 -04:00
|
|
|
%td POST
|
|
|
|
%td
|
2013-01-30 09:40:43 -05:00
|
|
|
= link_to 'Remove', admin_hook_path(hook), confirm: 'Are you sure?', method: :delete, class: "btn btn-remove btn-small pull-right"
|