diff options
author | James Edwards-Jones <jedwardsjones@gitlab.com> | 2018-03-07 02:20:01 +0300 |
---|---|---|
committer | James Edwards-Jones <jedwardsjones@gitlab.com> | 2018-03-08 03:09:26 +0300 |
commit | 93af1af67fc6af2805f3342aed1fc15a4360870d (patch) | |
tree | 5064b0355d44be4ad9d166b876e1176752f4af2b /app/views | |
parent | ef15668d8214e8cce5732525c872d5b8f57e337a (diff) |
Hides Triggers if integration only has one event
Removes confusing/unnecessary checkboxes when trying to configure an
integration. If there is only one supported event we don't need to
allow these to be individually disabled since the integration can be
disabled instead.
E.g. Project Integrations for GitHub, Bugzilla, Asana, Pipeline emails and Gemnasium
Allows integrations to override which triggers are configurable
Diffstat (limited to 'app/views')
-rw-r--r-- | app/views/shared/_service_settings.html.haml | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/app/views/shared/_service_settings.html.haml b/app/views/shared/_service_settings.html.haml index 61b39afb5d4..355b3ac75ae 100644 --- a/app/views/shared/_service_settings.html.haml +++ b/app/views/shared/_service_settings.html.haml @@ -13,12 +13,12 @@ .col-sm-10 = form.check_box :active, disabled: disable_fields_service?(@service) - - if @service.supported_events.present? + - if @service.configurable_events.present? .form-group = form.label :url, "Trigger", class: 'control-label' .col-sm-10 - - @service.supported_events.each do |event| + - @service.configurable_events.each do |event| %div = form.check_box service_event_field_name(event), class: 'pull-left' .prepend-left-20 |