Hello,
I'm currently trying to develop a menu binding the data from the datasource.... I've folowed your example at http://docs.kendoui.com/getting-started/using-kendo-with/aspnet-mvc/helpers/menu/overview
but I'm not able to load the children
My MenuItem is of type
What am I doing wrong? It only shows the first, it puts the arrow for opening but won't open...
Thanks
Paolo
I'm currently trying to develop a menu binding the data from the datasource.... I've folowed your example at http://docs.kendoui.com/getting-started/using-kendo-with/aspnet-mvc/helpers/menu/overview
but I'm not able to load the children
@(Html.Kendo().Menu().Name("menu").BindTo(Model, mappings =>
{
mappings.For<
IDEA20.DO.Common.MenuItem
>(binding =>
{
binding.ItemDataBound((item, category) => //define mapping between menu item properties and the model properties
{
item.Text = category.Text;
}).Children(category => category.SubMenu);
});
})
)
public class MenuItem
{
public MenuItem()
{
SubMenu = new List<
MenuItem
>();
}
public string Text { get; set; }
public string Controller { get; set; }
public string Action { get; set; }
public bool Selected { get; set; }
public List<
MenuItem
> SubMenu { get; private set; }
}
Thanks
Paolo