I wonder where to place the functionality to refresh a groupingcollection, in an advanceddatagrid, inside the Cairngorm framework?
I have an advanceddatagrid with a groupingcollection for displaying product data. When the application is initialized, the getProductsEvent is dispatched. This will invoke the getProductsCommand wich will invoke getProductsDelegate. The delegate gets the data from the server and the command (wich implements the IResponder interface) will transform the data into an ArrayCollection and assign it to ShopModelLocator.getInstance().products.
The problem is that the view (AdvancedDataGrid) is not updated after model.products is changed. To do this, you have to invoke GroupingCollection.refresh().
The model doens't need to know the view. So invoke GroupingCollection.refresh() from the getProductsCommand is not an option. What is the best location to implement the logic that refreshes the groupingCollection? What is best practise?