Commit 2b4e5c93 authored by Matija Čupić's avatar Matija Čupić

Use secret_key and secret_value in CI variable frontend

parent 53915c5c
...@@ -29,11 +29,11 @@ export default class VariableList { ...@@ -29,11 +29,11 @@ export default class VariableList {
selector: '.js-ci-variable-input-id', selector: '.js-ci-variable-input-id',
default: '', default: '',
}, },
key: { secret_key: {
selector: '.js-ci-variable-input-key', selector: '.js-ci-variable-input-key',
default: '', default: '',
}, },
value: { secret_value: {
selector: '.js-ci-variable-input-value', selector: '.js-ci-variable-input-value',
default: '', default: '',
}, },
...@@ -105,7 +105,7 @@ export default class VariableList { ...@@ -105,7 +105,7 @@ export default class VariableList {
setupToggleButtons($row[0]); setupToggleButtons($row[0]);
// Reset the resizable textarea // Reset the resizable textarea
$row.find(this.inputMap.value.selector).css('height', ''); $row.find(this.inputMap.secret_value.selector).css('height', '');
const $environmentSelect = $row.find('.js-variable-environment-toggle'); const $environmentSelect = $row.find('.js-variable-environment-toggle');
if ($environmentSelect.length) { if ($environmentSelect.length) {
...@@ -174,7 +174,7 @@ export default class VariableList { ...@@ -174,7 +174,7 @@ export default class VariableList {
} }
toggleEnableRow(isEnabled = true) { toggleEnableRow(isEnabled = true) {
this.$container.find(this.inputMap.key.selector).attr('disabled', !isEnabled); this.$container.find(this.inputMap.secret_key.selector).attr('disabled', !isEnabled);
this.$container.find('.js-row-remove-button').attr('disabled', !isEnabled); this.$container.find('.js-row-remove-button').attr('disabled', !isEnabled);
} }
......
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