Use secret_key and secret_value in CI variable frontend

This commit is contained in:
Matija Čupić 2018-03-17 12:37:48 +01:00
parent 53915c5c54
commit 2b4e5c938b
No known key found for this signature in database
GPG Key ID: 4BAF84FFACD2E5DE
1 changed files with 4 additions and 4 deletions

View File

@ -29,11 +29,11 @@ export default class VariableList {
selector: '.js-ci-variable-input-id',
default: '',
},
key: {
secret_key: {
selector: '.js-ci-variable-input-key',
default: '',
},
value: {
secret_value: {
selector: '.js-ci-variable-input-value',
default: '',
},
@ -105,7 +105,7 @@ export default class VariableList {
setupToggleButtons($row[0]);
// 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');
if ($environmentSelect.length) {
@ -174,7 +174,7 @@ export default class VariableList {
}
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);
}