I'm using Gantt + Taskboard in my project. We have a rule that "root tasks" (WBS Code 1, 2, 3 ...) should not appear in the taskboard. I've tried to use TaskRenderer and set display: none, it actually works, but it keeps showing the total count of tasks aside the column name.
My question is, how can I filter the tasks in the taskboard when the component is mounted?
It doesn't worked well. It's actually filtering the way I want, but the taskboard it is still showing all the records, like if ignores the filter. Should I do something after passing the chained task store?
// TaskInterface is just for typing issues. It extends from TaskModel;
// Filtering root tasks, those who does not have a parentId;
// Schedule == ProjectModel
chainedTaskStore = schedule.taskStore.chain(
(record: TaskInterface) => !record.parentId,
) as unknown as TaskInterface[];
This is my taskboard after filtering. Still showing the WBS 1 and 2 (root). Should I do something in my taskboardConfig? As you can see, the return of the chainedStore is working (allRecords == 2).
taskboard after filtering
Captura de tela de 2023-11-08 08-56-06.png (62.5 KiB) Viewed 831 times
That happened because you specified both: full project and task store separately. In case you need to have different dataset, you can't share project, you need to use separated project instance and chain all stores you need.