mirror of
https://github.com/hcengineering/platform.git
synced 2024-12-23 03:22:19 +03:00
UBER-48: custom fields for organization in leads (#3203)
Signed-off-by: Vyacheslav Tumanov <me@slavatumanov.me>
This commit is contained in:
parent
8fa49326a0
commit
88d62bcff5
@ -99,24 +99,22 @@
|
||||
/>
|
||||
</div>
|
||||
<svelte:fragment slot="pool">
|
||||
<div class="flex-row-center flex-wrap">
|
||||
<ChannelsDropdown
|
||||
bind:value={channels}
|
||||
focusIndex={10}
|
||||
kind={'secondary'}
|
||||
size={'large'}
|
||||
editable
|
||||
highlighted={matchedChannels.map((it) => it.provider)}
|
||||
/>
|
||||
<ChannelsDropdown
|
||||
bind:value={channels}
|
||||
focusIndex={10}
|
||||
kind={'secondary'}
|
||||
size={'large'}
|
||||
editable
|
||||
highlighted={matchedChannels.map((it) => it.provider)}
|
||||
/>
|
||||
|
||||
<InlineAttributeBar
|
||||
_class={contact.class.Organization}
|
||||
{object}
|
||||
toClass={contact.class.Contact}
|
||||
on:update
|
||||
extraProps={{ showNavigate: false }}
|
||||
/>
|
||||
</div>
|
||||
<InlineAttributeBar
|
||||
_class={contact.class.Organization}
|
||||
{object}
|
||||
toClass={contact.class.Contact}
|
||||
on:update
|
||||
extraProps={{ showNavigate: false }}
|
||||
/>
|
||||
</svelte:fragment>
|
||||
<svelte:fragment slot="footer">
|
||||
{#if matches.length > 0}
|
||||
|
@ -18,7 +18,7 @@
|
||||
import contact from '@hcengineering/contact-resources/src/plugin'
|
||||
import { AttachedData, Class, Data, Doc, generateId, MixinData, Ref, WithLookup } from '@hcengineering/core'
|
||||
import type { Customer } from '@hcengineering/lead'
|
||||
import { Card, getClient } from '@hcengineering/presentation'
|
||||
import { Card, getClient, InlineAttributeBar } from '@hcengineering/presentation'
|
||||
import {
|
||||
Button,
|
||||
createFocusManager,
|
||||
@ -71,7 +71,7 @@
|
||||
description: object.description
|
||||
}
|
||||
|
||||
const id = await client.createDoc(targetClass._id, contact.space.Contacts, candidate, customerId)
|
||||
const id = await client.createDoc(targetClass._id, contact.space.Contacts, { ...candidate, ...object }, customerId)
|
||||
await client.createMixin(
|
||||
id as Ref<Contact>,
|
||||
targetClass._id,
|
||||
@ -234,6 +234,15 @@
|
||||
editable
|
||||
highlighted={matchedChannels.map((it) => it.provider)}
|
||||
/>
|
||||
{#if targetClass._id === contact.class.Organization}
|
||||
<InlineAttributeBar
|
||||
_class={contact.class.Organization}
|
||||
{object}
|
||||
toClass={contact.class.Contact}
|
||||
on:update
|
||||
extraProps={{ showNavigate: false }}
|
||||
/>
|
||||
{/if}
|
||||
</svelte:fragment>
|
||||
<svelte:fragment slot="footer">
|
||||
{#if matches.length > 0}
|
||||
|
Loading…
Reference in New Issue
Block a user