Improve kanban view (#4441)

Signed-off-by: Denis Bykhov <bykhov.denis@gmail.com>
This commit is contained in:
Denis Bykhov 2024-01-25 12:25:17 +06:00 committed by GitHub
parent b15f94f885
commit 5a9774cc30
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 3 additions and 6 deletions

View File

@ -120,13 +120,9 @@
const lookup: Lookup<Issue> = {
...(options?.lookup ?? {}),
space: tracker.class.Project,
status: tracker.class.IssueStatus,
component: tracker.class.Component,
milestone: tracker.class.Milestone,
attachedTo: tracker.class.Issue,
_id: {
subIssues: tracker.class.Issue,
labels: tags.class.TagReference
subIssues: tracker.class.Issue
}
}

View File

@ -457,6 +457,7 @@ abstract class MongoAdapterBase implements DbAdapter {
res = (await cursor.toArray())[0]
} catch (e) {
console.error('error during executing cursor in findWithPipeline', clazz, cutObjectArray(query), options, e)
throw e
}
const result = res.results as WithLookup<T>[]
const total = options?.total === true ? res.totalCount?.shift()?.count ?? 0 : -1