PDA

View Full Version : [CLOSED] [2.4 bug] MenuPanel in GroupTabPanel Exception in render stream.



michaeld
Dec 12, 2013, 5:44 AM
This is an old test sample. I'm not even sure its up to date or valid, but it reproduces the problem I am having in production with 2.4 with a similar construct.


<%@ Page Language="C#" AutoEventWireup="true" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">

<title>Test</title>
</head>
<body>
<form id="form1" runat="server">
<div>

<ext:ResourceManager ID="rm" runat="server" />

<ext:Viewport runat="server" Layout="VBoxLayout">
<LayoutConfig>
<ext:VBoxLayoutConfig Align="Stretch" />
</LayoutConfig>
<Items>

<ext:Panel ID="Panel1" runat="server" Border="false" BodyBorder="0" Flex="1" Layout="VBoxLayout">
<LayoutConfig>
<ext:VBoxLayoutConfig Align="Stretch" />
</LayoutConfig>
<Items>

<ext:GroupTabPanel ID="GP" runat="server" TabWidth="130" ActiveGroupIndex="0" Border="false" Cls="GTabSel" Flex="1" AutoScroll="true">
<Items>

<ext:Panel runat="server">
<Items>

<ext:Portal runat="server" Title="Test 1" Cls="TagPort" >
<Items>

<ext:PortalColumn ID="PortalColumn1" runat="server" Cls="PortCol" BodyCls="PortColB" ColumnWidth="0.5" >
<Items>

<ext:Portlet ID="Portlet1" runat="server" Title="Portlet 1" Border="false" Cls="Port" BodyCls="PortB">
<Items>

<ext:MenuPanel runat="server" Title="Menu Panel" Frame="true" Collapsible="true" Closable="false" Margin="4" Cls="MPan" BodyCls="MPanB" Border="false" BodyBorder="0" Icon="Music">
</ext:MenuPanel>

</Items>
</ext:Portlet>
<ext:Portlet ID="Portlet3" runat="server" Title="Portlet 3" Padding="6" >
<Items>
<ext:MenuPanel runat="server" Title="Test" Frame="true" Collapsible="true">
</ext:MenuPanel>
</Items>
</ext:Portlet>

</Items>
</ext:PortalColumn>

<ext:PortalColumn ID="PortalColumn3" runat="server" Cls="PortCol" BodyCls="PortColB" ColumnWidth="0.5">
<Items>

<ext:Portlet ID="Portlet5" runat="server" Title="Portlet 1" Border="false" Cls="Port" BodyCls="PortB">
<Items>

<ext:MenuPanel ID="MenuPanel2" runat="server" Title="Event Type" Frame="true" Collapsible="true" Closable="false" Margin="4" Cls="MPan" BodyCls="MPanB" Border="false" BodyBorder="0" Icon="ArrowRight">
<Menu>
<Items>
<ext:MenuItem ID="MenuItem4" runat="server" Text="Test1" Href="/" Icon="ArrowRight" />
<ext:MenuItem ID="MenuItem5" runat="server" Text="Test2" Href="/" Icon="ArrowRight" />
<ext:MenuItem ID="MenuItem6" runat="server" Text="Test3" Href="/" Icon="ArrowRight" />
</Items>
</Menu>
</ext:MenuPanel>

</Items>
</ext:Portlet>
</Items>
</ext:PortalColumn>

</Items>
</ext:Portal>

</Items>
</ext:Panel>

<ext:Panel ID="Panel2" runat="server">
<Items>

<ext:Portal ID="Portal2" runat="server" Title="Test2" Cls="TagPort">
<Items>

<ext:PortalColumn ID="PortalColumn2" runat="server" Cls="PortCol" ColumnWidth=".5">
<Items>

<ext:Portlet ID="Portlet2"
runat="server"
Title="Portlet 1"
Padding="6" >
<Items>

<ext:MenuPanel ID="MenuPanel1" runat="server" Title="Test" Frame="true" Collapsible="true">
<Menu runat="server">
<Items>
<ext:MenuItem ID="MenuItem1" runat="server" Text="Test1" Href="/" />
<ext:MenuItem ID="MenuItem2" runat="server" Text="Test2" Href="/" />
<ext:MenuItem ID="MenuItem3" runat="server" Text="Test3" Href="/" />
</Items>
</Menu>
</ext:MenuPanel>


</Items>
</ext:Portlet>

<ext:Portlet ID="Portlet4"
runat="server"
Title="Portlet 1"
Padding="6" />

</Items>
</ext:PortalColumn>

</Items>
</ext:Portal>

</Items>
</ext:Panel>
<ext:Panel ID="Panel3" runat="server">
<Items>
<ext:Portal ID="Portal1" runat="server" Title="Test3" Cls="TagPort">
<Items>
</Items>
</ext:Portal>
</Items>
</ext:Panel>

</Items>
</ext:GroupTabPanel>

</Items>
</ext:Panel>

</Items>
</ext:Viewport>
</form>
</body>

This didn't happen in 2.3.x

Daniil
Dec 12, 2013, 6:53 AM
Hi @michaeld,

Thank you for the report!

A MenuPanel without a Menu causes the problem.

<ext:MenuPanel runat="server" />

For now, please define an empty Menu, at least.

<ext:MenuPanel runat="server">
<Menu runat="server" />
</ext:MenuPanel>

We are investigating.

Daniil
Dec 12, 2013, 12:55 PM
It has been fixed in the trunk.

michaeld
Dec 13, 2013, 5:02 AM
It has been fixed in the trunk.

Thanks. Looks good. Which rev fixed this? Also which rev is 2.4 on? It's not clear in the log.

Daniil
Dec 13, 2013, 5:13 AM
#5557 [FIX] Control must be added to LazyItems first (not Controls collection)