diff --git a/src/lang/en.js b/src/lang/en.js index 2d21abe1..41b81cf8 100644 --- a/src/lang/en.js +++ b/src/lang/en.js @@ -274,7 +274,8 @@ export default { registrationReason: 'Registration Reason', service: 'Service', person: 'Person', - enableTagPolicy: 'Enable MRF TagPolicy to manage user tags' + enableTagPolicy: 'Enable MRF TagPolicy to manage user tags', + confirmEnablingTagPolicy: 'Are you sure you want to add TagPolicy to the list of enabled MRF policies?' }, statuses: { statuses: 'Statuses', diff --git a/src/views/users/components/ModerationDropdown.vue b/src/views/users/components/ModerationDropdown.vue index 9df5e703..28156fc8 100644 --- a/src/views/users/components/ModerationDropdown.vue +++ b/src/views/users/components/ModerationDropdown.vue @@ -182,7 +182,20 @@ export default { this.$store.dispatch('DisableMfa', nickname) }, enableTagPolicy() { - this.$store.dispatch('EnableTagPolicy') + this.$confirm( + this.$t('users.confirmEnablingTagPolicy'), + { + confirmButtonText: 'Yes', + cancelButtonText: 'Cancel', + type: 'warning' + }).then(() => { + this.$store.dispatch('EnableTagPolicy') + }).catch(() => { + this.$message({ + type: 'info', + message: 'Canceled' + }) + }) }, getPasswordResetToken(nickname) { this.$emit('open-reset-token-dialog') diff --git a/src/views/users/components/MultipleUsersMenu.vue b/src/views/users/components/MultipleUsersMenu.vue index 276faa67..eb9f4826 100644 --- a/src/views/users/components/MultipleUsersMenu.vue +++ b/src/views/users/components/MultipleUsersMenu.vue @@ -258,7 +258,20 @@ export default { } }, enableTagPolicy() { - this.$store.dispatch('EnableTagPolicy') + this.$confirm( + this.$t('users.confirmEnablingTagPolicy'), + { + confirmButtonText: 'Yes', + cancelButtonText: 'Cancel', + type: 'warning' + }).then(() => { + this.$store.dispatch('EnableTagPolicy') + }).catch(() => { + this.$message({ + type: 'info', + message: 'Canceled' + }) + }) }, isLocalUser(user) { return user.nickname && user.local