Fix query clone respect mixins (#1631)

Signed-off-by: Andrey Sobolev <haiodo@gmail.com>
This commit is contained in:
Andrey Sobolev
2022-05-04 20:54:32 +06:00
committed by GitHub
parent dfbf2d5263
commit e4e2af93dc
12 changed files with 3053 additions and 5296 deletions
@@ -39,7 +39,6 @@
"@anticrm/activity-resources": "~0.6.0",
"@anticrm/activity": "~0.6.0",
"@anticrm/contact": "~0.6.5",
"just-clone": "^3.2.1",
"@anticrm/core": "~0.6.16"
}
}
@@ -18,7 +18,6 @@
import presentation, { createQuery, getClient } from '@anticrm/presentation'
import { Button, Grid, Icon, Label, ToggleWithLabel } from '@anticrm/ui'
import notification from '../plugin'
import justClone from 'just-clone'
const accountId = getCurrentAccount()._id
const typeQuery = createQuery()
@@ -42,7 +41,7 @@
providersQuery.query(notification.class.NotificationProvider, {}, (res) => (providers = res))
settingsQuery.query(notification.class.NotificationSetting, { space }, (res) => {
settings = convertToMap(res)
oldSettings = convertToMap(justClone(res))
oldSettings = convertToMap(client.getHierarchy().clone(res))
})
function convertToMap (
+1 -1
View File
@@ -160,7 +160,7 @@ function ShowPopup (
props?: Record<string, any>
}
): void {
const docs = Array.isArray(doc) ? doc : [doc]
const docs = Array.isArray(doc) ? doc : doc !== undefined ? [doc] : []
evt.preventDefault()
let cprops = {
...(props?.props ?? {})
+1 -2
View File
@@ -98,8 +98,7 @@ export async function doNavigate (
if (ex === undefined) {
const r = await client.findOne(props.spaceClass, {})
if (r !== undefined) {
loc.path[3] = r._id
navigate(loc)
loc.path[2] = r._id
}
}
}