I'd like to implement reordering of list elements using p:orderList and p:panel components. Initially there was a POJOs in list, but problem occurs even with a list of strings.
There is my bean:
public class BackingBean {
private List<String> list;
public void addDate() {
list.add(new Date().toString());
}
// Getters and setters...
}
My page source:
<p:orderList id="videos" value="#{bean.list}" var="date" itemValue="#{date}"
controlsLocation="none">
<p:column >
<p:panel header="#{date}" toggleable="true" toggleSpeed="500">
FC Barcelona is one of only three clubs...
</p:panel>
</p:column>
</p:orderList>
The problem is that every time I toggle one of the panels, all panels are minimized and maximized a few times, i.e. if there are three elements in the list, than all panels will be maximized/minimized three times. Am I wrong?