mirror of
https://github.com/n8n-io/n8n.git
synced 2024-12-25 04:34:06 -08:00
fix(editor): Fix event emit on credential sharing (#6922)
Fix event emit
This commit is contained in:
parent
a82107fb05
commit
297c3c91f2
|
@ -87,7 +87,7 @@
|
|||
:credentialId="credentialId"
|
||||
:credentialPermissions="credentialPermissions"
|
||||
:modalBus="modalBus"
|
||||
@change="onChangeSharedWith"
|
||||
@update:modelValue="onChangeSharedWith"
|
||||
/>
|
||||
</div>
|
||||
<div v-else-if="activeTab === 'details' && credentialType" :class="$style.mainContent">
|
||||
|
|
|
@ -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;
|
||||
}),
|
||||
|
|
Loading…
Reference in a new issue