diff --git a/plugins/gmail-resources/src/components/IntegrationSelector.svelte b/plugins/gmail-resources/src/components/IntegrationSelector.svelte index 9e93c19ce0..b0dd51492e 100644 --- a/plugins/gmail-resources/src/components/IntegrationSelector.svelte +++ b/plugins/gmail-resources/src/components/IntegrationSelector.svelte @@ -23,13 +23,13 @@ export let kind: ButtonKind = 'link' export let size: ButtonSize = 'small' - $: ids = Array.from(new Set(integrations.map((p) => p.space as string as Ref))) + $: ids = Array.from(new Set(integrations.map((p) => p.createdBy as Ref))) function change (e: CustomEvent | null>) { if (e.detail === null) { selected = undefined } else { - selected = integrations.find((p) => (p.space as string as Ref) === e.detail) + selected = integrations.find((p) => p.createdBy === e.detail) } } diff --git a/plugins/gmail-resources/src/components/NewMessage.svelte b/plugins/gmail-resources/src/components/NewMessage.svelte index 35e4ff0aa4..c91d22620d 100644 --- a/plugins/gmail-resources/src/components/NewMessage.svelte +++ b/plugins/gmail-resources/src/components/NewMessage.svelte @@ -16,7 +16,7 @@ import attachmentP, { Attachment } from '@hcengineering/attachment' import { AttachmentPresenter } from '@hcengineering/attachment-resources' import contact, { Channel, Contact, getName } from '@hcengineering/contact' - import { Account, Data, generateId, Ref } from '@hcengineering/core' + import { Data, generateId } from '@hcengineering/core' import { NewMessage, SharedMessage } from '@hcengineering/gmail' import { NotificationClientImpl } from '@hcengineering/notification-resources' import { getResource, setPlatformStatus, unknownError } from '@hcengineering/platform' @@ -65,7 +65,7 @@ { ...obj, attachments: attachments.length, - from: selectedIntegration.space as string as Ref, + from: selectedIntegration.createdBy, copy: copy .split(',') .map((m) => m.trim()) diff --git a/plugins/gmail-resources/src/components/NewMessages.svelte b/plugins/gmail-resources/src/components/NewMessages.svelte index d3c7262bf9..70406f7937 100644 --- a/plugins/gmail-resources/src/components/NewMessages.svelte +++ b/plugins/gmail-resources/src/components/NewMessages.svelte @@ -16,7 +16,7 @@ import attachmentP, { Attachment } from '@hcengineering/attachment' import { AttachmentPresenter } from '@hcengineering/attachment-resources' import contact, { Channel, Contact, getName as getContactName } from '@hcengineering/contact' - import { Account, generateId, getCurrentAccount, Ref, toIdMap } from '@hcengineering/core' + import { generateId, getCurrentAccount, Ref, toIdMap } from '@hcengineering/core' import { NotificationClientImpl } from '@hcengineering/notification-resources' import { getResource, setPlatformStatus, unknownError } from '@hcengineering/platform' import { createQuery, getClient } from '@hcengineering/presentation' @@ -80,7 +80,7 @@ content: message, to: channel.value, status: 'new', - from: selectedIntegration.space as string as Ref, + from: selectedIntegration.createdBy, copy: copy .split(',') .map((m) => m.trim())