Our flexible Kanban board for managing tasks with drag drop


Post by markus »

Hi,

We have an odd issue while using TaskBoard with a custom store, which is killing us.

We use Zutand stores to retrieve data, since our backend API is GraphQL. Once fetched we provide the data to a BryntumTaskBoardProjectModel as TaskModelConfig along with some additional data that we need.

To render the card content, we use a taskRenderer function that acceses task.originalData where we find our additional data.

That works perfectly until we want to update the content (by fetching new data from the backend). The renderer simply renders the old data (originalData seems not to be updated).

However, of we use different ids for the tasks (by adding a timestamp to the id for example), the data will be updated.

Any idea, what we do wrong? Any good React example of a TaskBoard the uses an external store?

Thanks a lot!

Markus


Post by tasnim »

Hi,

You should not use data from originalData, Instead you should use Fields to get/set the data
https://bryntum.com/products/taskboard/docs/api/TaskBoard/model/TaskModel#fields

You can find all the react demos here https://bryntum.com/products/taskboard/examples/ by clicking on the react icon

Would it be possible to share your code with us so we can check what you're doing wrong? And if you can provide some more details about your use case?


Post by markus »

Hi Tasnim,

Thanks a lot - problem solved.

Markus


Post Reply