mirror of
https://github.com/hcengineering/platform.git
synced 2025-05-30 04:05:39 +00:00
More filter fixes (#2342)
Signed-off-by: Denis Bykhov <bykhov.denis@gmail.com>
This commit is contained in:
parent
8287b4f465
commit
bfcbb73bc7
@ -92,9 +92,6 @@ export class TContact extends TDoc implements Contact {
|
||||
@Prop(TypeString(), contact.string.Location)
|
||||
@Index(IndexKind.FullText)
|
||||
city!: string
|
||||
|
||||
@Prop(TypeRef(core.class.Class), core.string.ClassLabel)
|
||||
declare _class: Ref<Class<this>>
|
||||
}
|
||||
|
||||
@Model(contact.class.Channel, core.class.AttachedDoc, DOMAIN_CHANNEL)
|
||||
|
@ -14,7 +14,7 @@
|
||||
//
|
||||
|
||||
import contact, { Employee } from '@hcengineering/contact'
|
||||
import type { Class, Domain, Markup, Ref } from '@hcengineering/core'
|
||||
import type { Domain, Markup, Ref } from '@hcengineering/core'
|
||||
import { IndexKind } from '@hcengineering/core'
|
||||
import { Document, documentId, DocumentVersion, RichDocumentContent, Step } from '@hcengineering/document'
|
||||
import {
|
||||
@ -86,9 +86,6 @@ export class TDocument extends TDoc implements Document {
|
||||
@Prop(Collection(tags.class.TagReference), document.string.Labels)
|
||||
labels?: number
|
||||
|
||||
@Prop(TypeRef(core.class.Class), core.string.ClassLabel)
|
||||
declare _class: Ref<Class<this>>
|
||||
|
||||
@Prop(TypeNumber(), document.string.Revision)
|
||||
@ReadOnly()
|
||||
@Hidden()
|
||||
|
@ -15,7 +15,7 @@
|
||||
|
||||
// To help typescript locate view plugin properly
|
||||
import type { Employee } from '@hcengineering/contact'
|
||||
import { Class, Doc, FindOptions, IndexKind, Ref } from '@hcengineering/core'
|
||||
import { Doc, FindOptions, IndexKind, Ref } from '@hcengineering/core'
|
||||
import { Customer, Funnel, Lead, leadId } from '@hcengineering/lead'
|
||||
import {
|
||||
Builder,
|
||||
@ -24,9 +24,9 @@ import {
|
||||
Mixin,
|
||||
Model,
|
||||
Prop,
|
||||
TypeMarkup,
|
||||
TypeRef,
|
||||
TypeString,
|
||||
TypeMarkup,
|
||||
UX
|
||||
} from '@hcengineering/model'
|
||||
import attachment from '@hcengineering/model-attachment'
|
||||
@ -34,7 +34,7 @@ import chunter from '@hcengineering/model-chunter'
|
||||
import contact, { TContact } from '@hcengineering/model-contact'
|
||||
import core from '@hcengineering/model-core'
|
||||
import task, { actionTemplates, TSpaceWithStates, TTask } from '@hcengineering/model-task'
|
||||
import view, { createAction, actionTemplates as viewTemplates } from '@hcengineering/model-view'
|
||||
import view, { actionTemplates as viewTemplates, createAction } from '@hcengineering/model-view'
|
||||
import workbench from '@hcengineering/model-workbench'
|
||||
import setting from '@hcengineering/setting'
|
||||
import lead from './plugin'
|
||||
@ -82,9 +82,6 @@ export class TCustomer extends TContact implements Customer {
|
||||
@Prop(TypeMarkup(), core.string.Description)
|
||||
@Index(IndexKind.FullText)
|
||||
description!: string
|
||||
|
||||
@Prop(TypeRef(core.class.Class), core.string.ClassLabel)
|
||||
declare _class: Ref<Class<this>>
|
||||
}
|
||||
|
||||
export function createModel (builder: Builder): void {
|
||||
|
@ -176,7 +176,6 @@
|
||||
{#if !loading}
|
||||
{#each $filterStore as filter, i}
|
||||
<FilterSection
|
||||
{_class}
|
||||
{filter}
|
||||
on:change={() => {
|
||||
makeQuery(query, $filterStore)
|
||||
|
@ -23,7 +23,6 @@
|
||||
import { createEventDispatcher, onDestroy } from 'svelte'
|
||||
import view from '../../plugin'
|
||||
|
||||
// export let _class: Ref<Class<Doc>>
|
||||
export let filter: Filter
|
||||
|
||||
$: currentFilter = filter.nested ? filter.nested : filter
|
||||
|
@ -119,7 +119,7 @@ abstract class MongoAdapterBase extends TxProcessor {
|
||||
const classes = this.hierarchy.getDescendants(baseClass)
|
||||
|
||||
// Only replace if not specified
|
||||
if (translated._class?.$in === undefined) {
|
||||
if (translated._class === undefined) {
|
||||
translated._class = { $in: classes }
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user