Hey,
I need the expanded cards and collapsed cards to hold after refresh.
How do I achieve that?
Support Forum
Hi,
I don't understand what you mean by expanded cards and collapsed cards, Could you please explain a bit further what do you mean by that?
Are you talking about swimlanes? https://bryntum.com/docs/taskboard/api/TaskBoard/feature/SwimlaneDrag
Let me add a screenshots for expanded and collapsed view for reference.
Last edited by sreyant suraneni on Thu Oct 20, 2022 10:57 am, edited 1 time in total.
To achieve that, Add a field to TaskModel to keep track if the card is expanded or collapsed, then apply CSS to expand/collapse based on that field in a task rendered
Here is an example of how you can add a new field
class MyTask extends TaskModel {
static get fields() {
return [
// Add a new field
{ name: 'myField', type : 'number', defaultValue : 0 }
];
}
...
}
And this is the taskRenderer
from docs https://bryntum.com/docs/taskboard/api/TaskBoard/view/TaskBoardBase#config-taskRenderer
Good Luck ,
Tasnim