summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTristan Read <tread@gitlab.com>2018-12-12 16:32:24 +0100
committerPeter Leitzen <pleitzen@gitlab.com>2019-01-02 15:29:32 +0100
commit146aa8b7e823a0a06bfd95c6fb82235803177447 (patch)
tree8704dedca8a2d615fc29d302f69c874c9d131541
parent928e11323e1da5d9f84ad3dee93837def5d0fc8e (diff)
downloadgitlab-ce-146aa8b7e823a0a06bfd95c6fb82235803177447.tar.gz
Place operations settings menu item and page behind feature flag
-rw-r--r--app/views/projects/settings/operations/show.html.haml47
-rw-r--r--app/views/projects/sidebar/_settings_operations.html.haml7
2 files changed, 28 insertions, 26 deletions
diff --git a/app/views/projects/settings/operations/show.html.haml b/app/views/projects/settings/operations/show.html.haml
index 91fb20d12ef..381e750bbd8 100644
--- a/app/views/projects/settings/operations/show.html.haml
+++ b/app/views/projects/settings/operations/show.html.haml
@@ -2,26 +2,27 @@
- page_title _('Operations Settings')
- page_title _('Operations')
-%section.settings.expanded
- .settings-header
- %h4
- = _('Error Tracking')
- %p
- = _('To link Sentry to Gitlab, enter your Sentry URL and bearer token')
- .settings-content
- / TODO: figure out how to use the form_for helper for this section
- %form
- .form-group
- %div.form-check
- %input.form-check-input(id='checkboxSentry' type='checkbox')
- %label(for='checkboxSentry')
- = _('Active')
- .form-group
- %label.label-bold
- = _('Sentry API URL')
- %input.form-control{:placeholder => _('http://<sentry-host>/<project>')}
- .form-group
- %label.label-bold
- = _('Bearer token')
- %input.form-control{:placeholder => _('Hint token')}
- %input.btn.btn-success{:type => 'submit', :value => _('Save changes')}
+- if Feature.enabled?(:error_tracking, @project, default_enabled: true)
+ %section.settings.expanded
+ .settings-header
+ %h4
+ = _('Error Tracking')
+ %p
+ = _('To link Sentry to Gitlab, enter your Sentry URL and bearer token')
+ .settings-content
+ / TODO: figure out how to use the form_for helper for this section
+ %form
+ .form-group
+ %div.form-check
+ %input.form-check-input(id='checkboxSentry' type='checkbox')
+ %label(for='checkboxSentry')
+ = _('Active')
+ .form-group
+ %label.label-bold
+ = _('Sentry API URL')
+ %input.form-control{:placeholder => _('http://<sentry-host>/<project>')}
+ .form-group
+ %label.label-bold
+ = _('Bearer token')
+ %input.form-control{:placeholder => _('Hint token')}
+ %input.btn.btn-success{:type => 'submit', :value => _('Save changes')}
diff --git a/app/views/projects/sidebar/_settings_operations.html.haml b/app/views/projects/sidebar/_settings_operations.html.haml
index e1a774a429a..31dbd729f18 100644
--- a/app/views/projects/sidebar/_settings_operations.html.haml
+++ b/app/views/projects/sidebar/_settings_operations.html.haml
@@ -1,3 +1,4 @@
-= nav_link(controller: [:operations]) do
- = link_to project_settings_operations_path(@project), title: _('Operations') do
- = _('Operations')
+- if Feature.enabled?(:error_tracking, @project, default_enabled: true)
+ = nav_link(controller: [:operations]) do
+ = link_to project_settings_operations_path(@project), title: _('Operations') do
+ = _('Operations')