Our blazing fast Grid component built with pure JavaScript


Post by npzi »

Hi Alex, thanks for the answer. The main problem I have is that I can't find a load event and no event seems suitable to trigger the loading of the grid. The grid must be completely loaded for this - a time-based carrier is a game with fire.


Post by alex.l »

Hi npzi,

If we are talking about the Gantt, please try this event https://bryntum.com/docs/gantt/#Gantt/model/ProjectModel#event-load
Also this one may be helpful https://bryntum.com/docs/gantt/#Gantt/model/ProjectModel#event-sync

If we are talking about the Grid, as you mentioned in your post, just use https://bryntum.com/docs/gantt/#Core/data/AjaxStore#event-load event that every remote store has

All the best,
Alex

All the best,
Alex


Post by npzi »

Hi Alex,

I'm talking about the Grid and in my case I use the Store instead of the AjaxStore and there is no load event.


Post by Mercury »

Hi npzi,

I'm no expert here but you might want to check out the refresh event on your store to catch loading:

Data in the store has completely changed, such as by a filter, or sort or load operation.

You could filter out any unwanted event cases with some logic.


Post by npzi »

Hi Mercury,

the problem is that these events are fired as soon as the data changes, but not when the view has been re-rendered. However, in order to load the state that is saved by the grid, the grid must first be rendered (or I have misunderstood).


Post by alex.l »

Hi npzi,

Store - is a data level, it shouldn't know about render operations. So if you want to know when data is ready, use store's events (such as https://bryntum.com/docs/grid/#Core/data/Store#event-change)

If you want to catch a moment when rows are rendered, please use https://bryntum.com/docs/grid/#Grid/view/Grid#event-renderRows

All the best,
Alex


Post Reply