fix(filters): correctly use date filters in gantt chart
continuous-integration/drone/pr Build is passing Details

This commit is contained in:
kolaente 2024-03-10 12:16:21 +01:00
parent 654e95d99f
commit 009e9b5455
Signed by: konrad
GPG Key ID: F40E70337AB24C9B
2 changed files with 3 additions and 1 deletions

View File

@ -33,6 +33,8 @@ The available fields for filtering include:
You can date math to set relative dates. Click on the date value in a query to find out more.
All strings must be either single-word or enclosed in `"` or `'`. This extends to date values like `2024-03-11`.
## Operators
The available operators for filtering include:

View File

@ -79,7 +79,7 @@ function ganttFiltersToApiParams(filters: GanttFilters): TaskFilterParams {
return {
sort_by: ['start_date', 'done', 'id'],
order_by: ['asc', 'asc', 'desc'],
filter: 'start_date >= ' + isoToKebabDate(filters.dateFrom) + ' && start_date <= ' + isoToKebabDate(filters.dateTo),
filter: 'start_date >= "' + isoToKebabDate(filters.dateFrom) + '" && start_date <= "' + isoToKebabDate(filters.dateTo) + '"',
filter_include_nulls: filters.showTasksWithoutDates,
}
}