Ticket #5757 (closed defect: fixed)
Setting the store in the DojoData model should only be done in the constructor
| Reported by: | benschell | Owned by: | jaredj |
|---|---|---|---|
| Priority: | normal | Milestone: | |
| Component: | DojoX Grid | Version: | 1.0 |
| Severity: | normal | Keywords: | |
| Cc: |
Description
If the store is set via:
var newModel = new dojox.grid.data.DojoData(); newModel.store = myStore;
problems will arise, as information about the store is setup during construction (attaching events, determining store capabilities, etc.). This same model should be created like so:
var newModel = new dojox.grid.data.DojoData({store: myStore});
This is only docs problem, and only occurs on one page. This should be changed so that users don't start setting the store directly, then running into notification, writing, and identity-fetching issues later.
This page should be changed to something like:
var newModel = new dojox.grid.data.DojoData({rowsPerPage: 20, store: myStore, query: {type: someOtherType}, clientSort: true});
myGrid.setModel(newModel);
// Remember to call newModel.destroy() when you're done.
Change History
Note: See
TracTickets for help on using
tickets.