PDA

View Full Version : [CLOSED] GridPanel Summary Feature failed to work with TreePanel SetRootNode() call



cleve
Feb 16, 2013, 11:47 PM
Hi guys,

It's weird when I come up the following code with error. It looks like gridpanel summary feature can't be with treepanel if I want to rebind the tree with setRootNode() call later on.




<%@ Import Namespace="ISS" %>
<%@ Page Language="C#" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<link href="/themes/shared.css" type="text/css" rel="stylesheet" />
</head>
<body id="theBody">
<ext:ResourceManager ID="theManager" runat="server"
IDMode="Static"
Theme="Default"
ShowWarningOnAjaxFailure="false"
DirectMethodProxy="Ignore"
ScriptMode="Debug">
</ext:ResourceManager>
<ext:Panel runat="server" Layout="BorderLayout" Height="450" Width="400">
<TopBar>
<ext:Toolbar runat="server">
<Items>
<ext:Button runat="server" Text="AAA">
<Listeners>
<Click Handler="testFunc();" />
</Listeners>
</ext:Button>
</Items>
</ext:Toolbar>
</TopBar>
<Items>
<ext:TreePanel runat="server" ID="tp" IDMode="Static" Width="200" Region="West" />
<ext:GridPanel runat="server" ID="gp" IDMode="Static" Region="Center">
<Store>
<ext:Store runat="server" ID="ds" AutoLoad="false">
<Model>
<ext:Model runat="server">
<Fields>
<ext:ModelField Name="comp" />
</Fields>
</ext:Model>
</Model>
<Listeners>
<Load Handler="a;" />
</Listeners>
</ext:Store>
</Store>
<ColumnModel>
<Columns>
<ext:SummaryColumn runat="server" DataIndex="A" Text="A" />
</Columns>
</ColumnModel>
<Features>
<ext:Summary runat="server" />
</Features>
<View>
<ext:GridView runat="server">
<GetRowClass Handler="return 'testCls';" />
</ext:GridView>
</View>
</ext:GridPanel>
</Items>
</ext:Panel>


<script type="text/javascript">


var testFunc = function () {
X.getCmp("tp").setRootNode({ text: "aaa" });
}


</script>


</body>
</html>
<script runat="server">


protected override void OnInit(EventArgs e)
{
base.OnInit(e);
}


</script>






Try the following:
1. Press button "AAA" error occurs says "childNodes parent null".
2. Erase <ext:Summary ... /> then press "AAA", works fine then.

Any comments?

Baidaly
Feb 17, 2013, 12:35 AM
Hello!

We are investigating!

Thank you!

Vladimir
Feb 17, 2013, 9:03 AM
Hi,

Yesterday, ExtJS version was updated in Ext.Net (now 4.2.0 RC)
The error is not reproducible anymore

cleve
Feb 17, 2013, 10:38 AM
Hi,

Yesterday, ExtJS version was updated in Ext.Net (now 4.2.0 RC)
The error is not reproducible anymore


You are right. It's solved. Please close then. Thanks.