summaryrefslogtreecommitdiff
path: root/src/views/AccessControl/LocalUserManagement/ModalSettings.vue
diff options
context:
space:
mode:
Diffstat (limited to 'src/views/AccessControl/LocalUserManagement/ModalSettings.vue')
-rw-r--r--src/views/AccessControl/LocalUserManagement/ModalSettings.vue38
1 files changed, 19 insertions, 19 deletions
diff --git a/src/views/AccessControl/LocalUserManagement/ModalSettings.vue b/src/views/AccessControl/LocalUserManagement/ModalSettings.vue
index a611c590..89a1ebca 100644
--- a/src/views/AccessControl/LocalUserManagement/ModalSettings.vue
+++ b/src/views/AccessControl/LocalUserManagement/ModalSettings.vue
@@ -19,7 +19,7 @@
{{
$t('global.form.valueMustBeBetween', {
min: 0,
- max: 65535
+ max: 65535,
})
}}
</b-form-text>
@@ -39,13 +39,13 @@
<template
v-if="
!$v.form.lockoutThreshold.minLength ||
- !$v.form.lockoutThreshold.maxLength
+ !$v.form.lockoutThreshold.maxLength
"
>
{{
$t('global.form.valueMustBeBetween', {
min: 0,
- max: 65535
+ max: 65535,
})
}}
</template>
@@ -104,7 +104,7 @@
</b-row>
</b-container>
</b-form>
- <template v-slot:modal-footer="{ ok, cancel }">
+ <template #modal-footer="{ ok, cancel }">
<b-button
variant="secondary"
data-test-id="localUserManagement-button-cancel"
@@ -131,7 +131,7 @@ import {
required,
requiredIf,
minValue,
- maxValue
+ maxValue,
} from 'vuelidate/lib/validators';
export default {
@@ -139,42 +139,42 @@ export default {
props: {
settings: {
type: Object,
- required: true
- }
+ required: true,
+ },
},
data() {
return {
form: {
lockoutThreshold: 0,
unlockMethod: 0,
- lockoutDuration: null
- }
+ lockoutDuration: null,
+ },
};
},
watch: {
- settings: function({ lockoutThreshold, lockoutDuration }) {
+ settings: function ({ lockoutThreshold, lockoutDuration }) {
this.form.lockoutThreshold = lockoutThreshold;
this.form.unlockMethod = lockoutDuration ? 1 : 0;
this.form.lockoutDuration = lockoutDuration ? lockoutDuration : null;
- }
+ },
},
validations: {
form: {
lockoutThreshold: {
minValue: minValue(0),
maxValue: maxValue(65535),
- required
+ required,
},
unlockMethod: { required },
lockoutDuration: {
- minValue: function(value) {
+ minValue: function (value) {
return this.form.unlockMethod === 0 || value > 0;
},
- required: requiredIf(function() {
+ required: requiredIf(function () {
return this.form.unlockMethod === 1;
- })
- }
- }
+ }),
+ },
+ },
},
methods: {
handleSubmit() {
@@ -213,7 +213,7 @@ export default {
? this.settings.lockoutDuration
: null;
this.$v.$reset(); // clear validations
- }
- }
+ },
+ },
};
</script>