Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
Clear All
new posts

    Question about ListGrid groupBy and getGroupByFields()

    Hello,

    It appears that if I have a ListGrid, once I set grid.groupBy(fields), and soon after call grid.getGroupByFields(), it will sometimes return null. Is this the intended behavior? When is getGroupByFields() a reliable call to make?

    The documentation says " If this grid is not currently grouped, this method will return null." - at what specific time will it no longer return null? After the GroupByComplete handler is called?

    #2
    Yes, after the groupByComplete() handler is called. Grouping is necessarily asynchronous in order to handle larger datasets. Before groupByComplete, the getGroupByFields() API is accurately returning that the grid is not yet grouped - there is no groupTree available, etc.

    Comment

    Working...
    X