-
30 Oct 2012 3:27 PM #1
2.1.0-rc2 NestedList Grouped and Grouper no longer work
2.1.0-rc2 NestedList Grouped and Grouper no longer work
Touch 2.1.0-rc2
In 2.0.1.1 in the NestedList listchange event it is possible to set up a Grouped on the List and a Grouper on the list.getStore().
This no longer works in 2.1.0-rc2
ThanksCode:Ext.setup({ onReady: function () { var data = { text: 'Groceries', items: [{ text: 'Drinks', gp: 'D', items: [{ text: 'Water', gp: "W", items: [{ text: 'Sparkling', gp: "S", leaf: true }, { text: 'Still', gp: "S", leaf: true }, { text: 'Deep', gp: "D", leaf: true }, { text: 'Muddy', gp: "M", leaf: true }] }, { text: 'Ale', gp: 'A', leaf: true }] }, { text: 'Lager', gp: "L", leaf: true }] }; Ext.define('ListItem', { extend: 'Ext.data.Model', config: { fields: [{ name: 'text', type: 'string' }, { name: 'gp', type: 'string' }] } }); var store = Ext.create('Ext.data.TreeStore', { model: 'ListItem', defaultRootProperty: 'items', root: data }); var nestedList = Ext.create('Ext.NestedList', { fullscreen: true, title: 'Groceries', displayField: 'text', store: store, listeners: { listchange: function (nlist, list) { var liststore = list.getStore(); liststore.setGrouper({ groupFn: function (record) { return record.get("gp"); } }); list.setGrouped(true); } } }); } });
David
-
30 Oct 2012 4:19 PM #2Sencha - Senior Forum Manager
- Join Date
- Mar 2007
- Location
- St. Louis, MO
- Posts
- 33,675
- Vote Rating
- 435
Thanks for the report! I have opened a bug in our bug tracker.
Success! Looks like we've fixed this one. According to our records the fix was applied for
TOUCH-3641
in
Sprint 27.


Reply With Quote