fix(filters): pass correct filter query to kanban and gantt loading
This commit is contained in:
parent
d0b762d761
commit
38985a8318
@ -296,6 +296,7 @@ import {calculateItemPosition} from '@/helpers/calculateItemPosition'
|
||||
import {isSavedFilter} from '@/services/savedFilter'
|
||||
import {success} from '@/message'
|
||||
import {useProjectStore} from '@/stores/projects'
|
||||
import type {TaskFilterParams} from '@/services/taskCollection'
|
||||
|
||||
const {
|
||||
projectId = undefined,
|
||||
@ -347,11 +348,12 @@ const collapsedBuckets = ref<CollapsedBuckets>({})
|
||||
const taskUpdating = ref<{[id: ITask['id']]: boolean}>({})
|
||||
const oneTaskUpdating = ref(false)
|
||||
|
||||
const params = ref({
|
||||
filter_by: [],
|
||||
filter_value: [],
|
||||
filter_comparator: [],
|
||||
filter_concat: 'and',
|
||||
const params = ref<TaskFilterParams>({
|
||||
sort_by: [],
|
||||
order_by: [],
|
||||
filter: '',
|
||||
filter_include_nulls: false,
|
||||
s: '',
|
||||
})
|
||||
|
||||
const getTaskDraggableTaskComponentData = computed(() => (bucket: IBucket) => {
|
||||
|
@ -79,10 +79,7 @@ function ganttFiltersToApiParams(filters: GanttFilters): TaskFilterParams {
|
||||
return {
|
||||
sort_by: ['start_date', 'done', 'id'],
|
||||
order_by: ['asc', 'asc', 'desc'],
|
||||
filter_by: ['start_date', 'start_date'],
|
||||
filter_comparator: ['greater_equals', 'less_equals'],
|
||||
filter_value: [isoToKebabDate(filters.dateFrom), isoToKebabDate(filters.dateTo)],
|
||||
filter_concat: 'and',
|
||||
filter: 'start_date >= ' + isoToKebabDate(filters.dateFrom) + ' && start_date <= ' + isoToKebabDate(filters.dateTo),
|
||||
filter_include_nulls: filters.showTasksWithoutDates,
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user