-
4 Mar 2013 12:28 AM #1
Tree Error in ExtJS 4.2-beta
Tree Error in ExtJS 4.2-beta
When check first node - disappear second node too in chome and firefox.Code:Ext.widget("window", { autoShow: true, width: 320, height: 120, layout: "fit", items: [{ xtype: "treepanel", rootVisible: false, store: Ext.create("Ext.data.TreeStore", { root: { children: [{ "checked": false, "text": "1", "expanded": true, "children": [{ "text": "1.1", "expanded": true, "children": [{ "text": "1.1.1" }, { "text": "1.1.2" }, { "text": "1.1.3" }] }, { "text": "1.2", "expanded": true, "children": [{ "text": "1.2.1" }, { "text": "1.2.2" }, { "text": "1.2.3" }] }] }, { "text": "2", "children": [{ "text": "2.1", "children": [{ "text": "2.1.1" }, { "text": "2.1.2" }, { "text": "2.1.3" }] }] }], expanded: true } }), listeners: { checkchange: function (node, checked) { var i; node.removeAll(); } } }] });
-
4 Mar 2013 12:48 AM #2
Thanks for the report! I have opened a bug in our bug tracker.
-
4 Mar 2013 1:12 AM #3
Is this not just your checkchange listener removing all child nodes from any node which has its checked status changed?
Search the forum: http://www.google.com/coop/cse?cx=01...%3Az7of1ufqccu
Read the docs too: http://extjs.com/deploy/dev/docs/
Scope: http://extjs.com/forum/showthread.ph...642#post257642
-
4 Mar 2013 1:17 AM #4
chrome debugger enter in this handler for only one time. If I'll sort store - disappeared nodes showed up.
And on 4.1.1 this code works flawless
-
4 Mar 2013 1:52 AM #5
I can't understand you.
You have a checked handler which removes the nodes. So that's why they disappear.
What is this new information about sorting?Search the forum: http://www.google.com/coop/cse?cx=01...%3Az7of1ufqccu
Read the docs too: http://extjs.com/deploy/dev/docs/
Scope: http://extjs.com/forum/showthread.ph...642#post257642
-
4 Mar 2013 3:26 AM #6
if I call tree.getStore().sort("text") /* or any other column */ in some cases it show disappeared nodes. But anyway it don't works fine - some nodes can doubles, on again sort trying it throw exception... I can't found workaround for some hours :-(
-
4 Mar 2013 3:33 AM #7
I think this is a bug which is fixed, but the code is unreleased.
It works here, so in the GA, I think you will be fine.Search the forum: http://www.google.com/coop/cse?cx=01...%3Az7of1ufqccu
Read the docs too: http://extjs.com/deploy/dev/docs/
Scope: http://extjs.com/forum/showthread.ph...642#post257642
-
4 Mar 2013 3:50 AM #8
thx a lot. Сan you make me happy told when it will come about? :-)
-
4 Mar 2013 3:53 AM #9
Very soon!
Search the forum: http://www.google.com/coop/cse?cx=01...%3Az7of1ufqccu
Read the docs too: http://extjs.com/deploy/dev/docs/
Scope: http://extjs.com/forum/showthread.ph...642#post257642
-
26 Mar 2013 11:31 PM #10
same error in ExtJS 4.2.0-gpl:
Can be looked at jsfiddle: 8L2TACode:Ext.widget("window", { autoShow: true, width: 320, height: 240, layout: "fit", items: [{ xtype: "treepanel", rootVisible: false, store: Ext.create("Ext.data.TreeStore", { root: { children: [{ "checked": false, "text": "1", "expanded": true, "children": [{ "text": "1.1", "expanded": true, "children": [{ "text": "1.1.1" }, { "text": "1.1.2" }, { "text": "1.1.3" }] }, { "text": "1.2", "expanded": true, "children": [{ "text": "1.2.1" }, { "text": "1.2.2" }, { "text": "1.2.3" }] }] }, { "text": "2", "children": [{ "text": "2.1", "children": [{ "text": "2.1.1" }, { "text": "2.1.2" }, { "text": "2.1.3" }] }] }], expanded: true } }), listeners: { checkchange: function (node, checked) { node.removeAll(); node.appendChild({ text: 1, expanded: true, children: [{ text: 2, expanded: true, children: [{ text: 3, //<- it will be hidden expanded: true, children: [] }] }] }); } } }] });
You found a bug! We've classified it as
EXTJSIV-8949
.
We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.


Reply With Quote