jsp - is there a way to collapse all the panels of Kendo Panelbar, on an action? -
i working on app adding panelbars (multiselection) using jsp wrapper (which means no id each of panels), , inside have grids.
the grids storing data specific selected person, displayed list items(images) on top of page.
what want when user changes selection of person, current selected another, collapse panels of kendo panelbar. in reloading data of new person, because when user select/expand panel see data, catch event , reload grid new datasource, based on selected person.
i hope make sense here, not sure how collapse panels of panelbar.
any suggestions??
if id
of panelbar
panel
, do:
$("#panel").data("kendopanelbar").collapse($("li", "#panelbar"));
or
var panelbar = $("#panelbar").data("kendopanelbar"); panelbar.collapse($("li", panelbar.element));
i.e. collapse
every li
element under #panelbar
.
edit: if want remove selection, add:
$(".k-state-selected", panelbar.element).removeclass("k-state-selected");
Comments
Post a Comment