Jul 02, 2013, 2:19 PM
[CLOSED] [2.x] - MVC - Dynamic PortalColumn
Hi,
I try to create a dynamic PortalColumn and run into the error "TypeError: items[0] is undefined.
items[0].addCls('x-portal-column-first');".
I wonder what is the issue.
Following is my test.
View
I try to create a dynamic PortalColumn and run into the error "TypeError: items[0] is undefined.
items[0].addCls('x-portal-column-first');".
I wonder what is the issue.
Following is my test.
View
@{
ViewBag.Title = "Server Status Center";
var X = Html.X();
}
@(X.ResourceManager())
@(X.Portal()
.ID("Portal_Main")
.Region(Region.Center)
.Border(false)
.Flex(1)
.BodyStyle("background-color:transparent")
.Loader(X.ComponentLoader().Url(Url.Action("RenderServerStatusColumn")).Mode(LoadMode.Component).Params(new { containerId = "Portal_Main" }))
)
Controllerpublic ContentResult RenderServerStatusColumn(string containerId)
{
var compLoader = new ComponentLoader
{
Url = Url.Action("http://www.ext.net"),
DisableCaching = true,
Mode = LoadMode.Frame,
};
var portalcolumn = new PortalColumn { ID = "PortalColumn_01", ColumnWidth = 0.5 };
return Content(ComponentLoader.ToConfig(
new List<AbstractComponent>()
{
portalcolumn
}
));
}
Last edited by Daniil; Jul 03, 2013 at 3:39 AM.
Reason: [CLOSED]