Commit 6361e8e7 authored by Shinya Maeda's avatar Shinya Maeda

Disable environemt variable for Group-level variables

parent 29342210
%h4.prepend-top-0
Secret variables
= link_to icon('question-circle'), help_page_path('ci/variables/README', anchor: 'secret-variables'), target: '_blank'
- if @project.feature_available?(:variable_environment_scope)
- if @variable.is_a?(Ci::VariablePresenter) && @project.feature_available?(:variable_environment_scope)
%p
These variables will be set to environment by the runner, and could be protected by exposing only to protected branches or tags, or some particular environments.
- else
......
......@@ -7,7 +7,8 @@
.form-group
= f.label :value, "Value", class: "label-light"
= f.text_area :value, class: "form-control", placeholder: @variable.placeholder
= render 'projects/variables/ee/environment_scope', f: f
- if @variable.is_a?(Ci::VariablePresenter)
= render 'projects/variables/ee/environment_scope', f: f
.form-group
.checkbox
= f.label :protected do
......
......@@ -9,7 +9,7 @@
%th Key
%th Value
%th Protected
- if @project.feature_available?(:variable_environment_scope)
- if @variable.is_a?(Ci::VariablePresenter) && @project.feature_available?(:variable_environment_scope)
%th Environment scope
%th
%tbody
......@@ -19,7 +19,7 @@
%td.variable-key= variable.key
%td.variable-value{ "data-value" => variable.value }******
%td.variable-protected= Gitlab::Utils.boolean_to_yes_no(variable.protected)
- if @project.feature_available?(:variable_environment_scope)
- if @variable.is_a?(Ci::VariablePresenter) && @project.feature_available?(:variable_environment_scope)
%td.variable-environment-scope= variable.environment_scope
%td.variable-menu
= link_to variable.edit_path, class: "btn btn-transparent btn-variable-edit" do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment