PDA

View Full Version : [FIXED] TreeStore and TreePanel bugs



billtricarico
31 Jan 2012, 9:51 PM
Using Designer 2, I have noticed two things regarding trees:

1) I created a TreeStore and pointed it to a json file. I created a tree Model with 2 string fields, 'id' and 'text', which I bind to the TreeStore. I load the data into the store and I see the eye, which I guess means the data has been loaded. When I click the eye, I get the error:


TypeError: 'undefined' is not an object.

2) I created a TreePanel as a top-level class. I linked it to an inner component. I gave it an id. However, the store attribute is just an empty combobox. I expected it to contain the store names as if I manipulating the top level component.

As an aside....if I create the TreePanel as a top-level class, and link it to other parts of the app, is it strictly necessary to bind a store to the class-level TreePanel? I would think no, since that is just a class, and not a link/instantiation.

Thanks.

aconran
31 Jan 2012, 10:43 PM
Thanks for reporting these. Both cases are legitimate bugs.

1) Is due to a bad assumption on our part assuming that all stores have a "data" configuration. TreeStore's do not have this configuration.

2) This doesn't work properly at the moment but I will describe how it *should* work.

The top level class can store a default treestore to use in the case that a user does not specify another. If a user specifies a different store on a linked instance that is being used it will override that default.

aconran
9 Feb 2012, 6:45 PM
Both of these bugs have been fixed. Bug #1 was fixed in build 276 and bug #2 will be fixed in the next build released.

Bug #2 was closely related to DSGNR-1305:
http://www.sencha.com/forum/showthread.php?178270