ServiceStore gets except on getValues(item, attr) when attr not defined
If we have a treenode in the tree (one that has mayHaveChildren return tree, therefore could potentially have a children) that has no children and we try to open it. It gets stuck in the animation, and errors out with the message "args.item is undefined". Once upon a time the behavior was to just open the node to an empty content and I'm being told that it's the behavior it should still have. This is therefore a bug. Find a test file attached.
Change History (6)
Resolution: |
→ invalid
|
Status: |
new →
closed
|
Component: |
Dijit →
Data
|
Resolution: |
invalid
|
Status: |
closed →
reopened
|
Summary: |
Treenode with no children is stuck in the animation when we try to pen it. →
ServiceStore gets except on getValues(item, attr) when attr not defined
|
Owner: |
set to Kris Zyp
|
Status: |
reopened →
new
|
Resolution: |
→ fixed
|
Status: |
new →
closed
|
There's a typo in your test case where it tries to load a root of "testTreeRoot2", yet your only data file is called "treeTestRoot2". But after fixing that, I can see the real problem is that your leaf nodes don't have children: [] attributes, and that confuses the ServiceStore code when Tree queries to find the children of those items.
There are provisions in ServiceStore for deferred loading of items. However, your test case doesn't have that setup. It would need to do deferred loading which would create the empty array children attribute.