-
17 Feb 2012 9:05 PM #1
Unanswered: Simple NestedList not showing up ! (sencha beta 3)
Unanswered: Simple NestedList not showing up ! (sencha beta 3)
I am using NestedList code from documentation as is. Just doesn't work ! Anything wrong in following ? Shows empty when displayed. I have been trying my own code but realized this simple code also does not work.
Code:var data = { text: 'Groceries', items: [{ text: 'Drinks', items: [{ text: 'Water', items: [{ text: 'Sparkling', leaf: true }, { text: 'Still', leaf: true }] }, { text: 'Coffee', leaf: true }, { text: 'Espresso', leaf: true }, { text: 'Redbull', leaf: true }, { text: 'Coke', leaf: true }, { text: 'Diet Coke', leaf: true }] }, { text: 'Fruit', items: [{ text: 'Bananas', leaf: true }, { text: 'Lemon', leaf: true }] }, { text: 'Snacks', items: [{ text: 'Nuts', leaf: true }, { text: 'Pretzels', leaf: true }, { text: 'Wasabi Peas', leaf: true }] }] }; Ext.define('ListItem', { extend: 'Ext.data.Model', fields: [{ name: 'text', 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 }); Ext.application({ name: 'xyz', phoneStartupScreen: 'images/b.jpg', launch: function() { var nestedList = Ext.create('Ext.NestedList', { fullscreen: true, title: 'Groceries', displayField: 'text', store: store } });
-
18 Feb 2012 2:33 PM #2
Jamie - This is the issue I was talking about in other thread.
-
18 Feb 2012 3:26 PM #3Sencha - Sencha Touch Dev Team
- Join Date
- Mar 2007
- Location
- Redwood City, California
- Posts
- 3,651
- Vote Rating
- 14
- Answers
- 17
So this runs fine in B3, but there are some warnings that need to be fixed. So it will only run in Compat mode until those are fixed. In particular this issue:
[WARN] fields is deprecated as a property directly on the Model prototype. Please put it inside the config object.
-
18 Feb 2012 3:51 PM #4
Thanks. I am not sure if I understand you correctly. Do you mean this is known issue and current workaround is to use compact mode of senchatouch-all ?
-
18 Feb 2012 4:46 PM #5Sencha - Sencha Touch Dev Team
- Join Date
- Mar 2007
- Location
- Redwood City, California
- Posts
- 3,651
- Vote Rating
- 14
- Answers
- 17
If you want to use deprecated methods, then you have to use the compat build.


Reply With Quote