Hi,
I'm trying to change o the fly the avatars of the resourceassigment column.
Is it possible to switch between names and avatrs? if so, could you tell me how can apply it?
Thank you in advance
Yes, Of course. You could use https://bryntum.com/products/gantt/docs/api/Gantt/model/ProjectModel#property-resources to set new data of resources
Here is a gif of the output
Thank you Tasnim.
My question was more about the way the resources are displayed on the column cell. In your example I see how you change the resources data dynamicaly, but the resources are always displayed as avatar (Image). What I would like to do is just to change the way the resources are displayed on the cells. Removing the images and getting the names, and then return to the avatar images.
How I could do that?
Thank you
Hello,
Then you could set image
or imageUrl
in the resource to null
.
gantt.project.resourceStore.forEach(item => { item.image = null; });
https://bryntum.com/products/gantt/docs/api/Gantt/model/ResourceModel#field-image
https://bryntum.com/products/gantt/docs/api/Gantt/model/ResourceModel#field-imageUrl
Is this what you're looking for