mirror of
https://github.com/n8n-io/n8n.git
synced 2024-11-12 15:44: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"
|
:credentialId="credentialId"
|
||||||
:credentialPermissions="credentialPermissions"
|
:credentialPermissions="credentialPermissions"
|
||||||
:modalBus="modalBus"
|
:modalBus="modalBus"
|
||||||
@change="onChangeSharedWith"
|
@update:modelValue="onChangeSharedWith"
|
||||||
/>
|
/>
|
||||||
</div>
|
</div>
|
||||||
<div v-else-if="activeTab === 'details' && credentialType" :class="$style.mainContent">
|
<div v-else-if="activeTab === 'details' && credentialType" :class="$style.mainContent">
|
||||||
|
|
|
@ -147,7 +147,7 @@ export default defineComponent({
|
||||||
methods: {
|
methods: {
|
||||||
async onAddSharee(userId: string) {
|
async onAddSharee(userId: string) {
|
||||||
const sharee = { ...this.usersStore.getUserById(userId), isOwner: false };
|
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) {
|
async onRemoveSharee(userId: string) {
|
||||||
const user = this.usersStore.getUserById(userId);
|
const user = this.usersStore.getUserById(userId);
|
||||||
|
@ -170,7 +170,7 @@ export default defineComponent({
|
||||||
|
|
||||||
if (confirm === MODAL_CONFIRM) {
|
if (confirm === MODAL_CONFIRM) {
|
||||||
this.$emit(
|
this.$emit(
|
||||||
'change',
|
'update:modelValue',
|
||||||
this.credentialData.sharedWith.filter((sharee: IUser) => {
|
this.credentialData.sharedWith.filter((sharee: IUser) => {
|
||||||
return sharee.id !== user.id;
|
return sharee.id !== user.id;
|
||||||
}),
|
}),
|
||||||
|
|
Loading…
Reference in a new issue