From 297c3c91f23a47b1aa78323d2b6e5677fbab8402 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Iv=C3=A1n=20Ovejero?= Date: Mon, 14 Aug 2023 13:32:23 +0200 Subject: [PATCH] fix(editor): Fix event emit on credential sharing (#6922) Fix event emit --- .../src/components/CredentialEdit/CredentialEdit.vue | 2 +- .../src/components/CredentialEdit/CredentialSharing.ee.vue | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue b/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue index 676c9d1b0..c946a94c0 100644 --- a/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue +++ b/packages/editor-ui/src/components/CredentialEdit/CredentialEdit.vue @@ -87,7 +87,7 @@ :credentialId="credentialId" :credentialPermissions="credentialPermissions" :modalBus="modalBus" - @change="onChangeSharedWith" + @update:modelValue="onChangeSharedWith" />
diff --git a/packages/editor-ui/src/components/CredentialEdit/CredentialSharing.ee.vue b/packages/editor-ui/src/components/CredentialEdit/CredentialSharing.ee.vue index 0f9122622..a87a3e8e8 100644 --- a/packages/editor-ui/src/components/CredentialEdit/CredentialSharing.ee.vue +++ b/packages/editor-ui/src/components/CredentialEdit/CredentialSharing.ee.vue @@ -147,7 +147,7 @@ export default defineComponent({ methods: { async onAddSharee(userId: string) { const sharee = { ...this.usersStore.getUserById(userId), isOwner: false }; - this.$emit('change', (this.credentialData.sharedWith || []).concat(sharee)); + this.$emit('update:modelValue', (this.credentialData.sharedWith || []).concat(sharee)); }, async onRemoveSharee(userId: string) { const user = this.usersStore.getUserById(userId); @@ -170,7 +170,7 @@ export default defineComponent({ if (confirm === MODAL_CONFIRM) { this.$emit( - 'change', + 'update:modelValue', this.credentialData.sharedWith.filter((sharee: IUser) => { return sharee.id !== user.id; }),