fix: Remove delete sharee prompt except when deleting last cred accessor (no-changelog) (#4894)

* fix: Remove delete sharee prompt except when deleting last cred accessor (no-changelog)

* chore: Remove unused translation
This commit is contained in:
Alex Grozav 2022-12-12 14:44:29 +02:00 committed by GitHub
parent 7d2e2ee0f7
commit ca8e85933f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 3 deletions

View file

@ -282,9 +282,9 @@ export default mixins(
const isLastUserWithAccessToCredentials = Object.values(isLastUserWithAccessToCredentialsById).some((value) => value);
let confirm = true;
if (!isNewSharee) {
if (!isNewSharee && isLastUserWithAccessToCredentials) {
confirm = await this.confirmMessage(
this.$locale.baseText(`workflows.shareModal.list.delete.confirm.${isLastUserWithAccessToCredentials ? 'lastUserWithAccessToCredentials.' : ''}message`, {
this.$locale.baseText(`workflows.shareModal.list.delete.confirm.lastUserWithAccessToCredentials.message`, {
interpolate: { name: user.fullName as string, workflow: this.workflow.name },
}),
this.$locale.baseText('workflows.shareModal.list.delete.confirm.title', { interpolate: { name: user.fullName } }),

View file

@ -1399,7 +1399,6 @@
"workflows.shareModal.select.placeholder": "Add people",
"workflows.shareModal.list.delete": "Remove access",
"workflows.shareModal.list.delete.confirm.title": "Remove {name}'s access?",
"workflows.shareModal.list.delete.confirm.message": "{name} will no longer have access to the workflow.",
"workflows.shareModal.list.delete.confirm.lastUserWithAccessToCredentials.message": "<strong>This might cause the workflow to stop working:</strong> {name} is the only user with access to credentials used in this workflow, those credentials will also be removed from {workflow}.",
"workflows.shareModal.list.delete.confirm.confirmButtonText": "Remove access",
"workflows.shareModal.list.delete.confirm.cancelButtonText": "Cancel",