Feb 11, 2014, 6:00 AM
Mvc - TreePanel click on Node
Hi everyone ,
i got a TreePanel with a few nodes. I'd like to add a Direct Method or sth like that on every single node, so that i can call a method
on the Controller with the oid of the node as parameter. I already tried with a Listener (not the one posted for the filter) but that didn't work for me.
i got a TreePanel with a few nodes. I'd like to add a Direct Method or sth like that on every single node, so that i can call a method
on the Controller with the oid of the node as parameter. I already tried with a Listener (not the one posted for the filter) but that didn't work for me.
@section example
{
@(X.TreePanel()
.Width(200)
.Height(400)
.Title("Foldercontent")
.Icon(Icon.ChartOrganisation)
.TopBarItem(
Html.X().ToolbarTextItem().Text("Filter:"),
Html.X().ToolbarSpacer(),
Html.X().TriggerField()
.EnableKeyEvents(true)
.Triggers(
Html.X().FieldTrigger().Icon(TriggerIcon.Clear)
)
.Listeners(l =>
{
l.KeyUp.Fn = "filterTree";
l.KeyUp.Buffer = 250;
l.TriggerClick.Fn = "clearFilter";
})
)
.Fields(
X.ModelField().Name("oid"),
X.ModelField().Name("dirname")
)
.RootVisible(true)
.Root(Model)
)
}
best regards.
Last edited by novacp; Feb 11, 2014 at 6:09 AM.