There's a checkbox inside a form that needs to be double-clicked for values to be passed to the bean. I suppose there's a double submit, but don't know how to get rid of it.
Code right now:
<p:selectManyCheckbox id="displayBy" style="font-size: 12px" value="#{detailedDashboardMB.displayBy}" valueChangeListener="#{detailedDashboardMB.onDisplayByClick}" columns="6" layout="grid">
<f:ajax render=":messages:growl detailed-chart" />
<f:selectItem itemLabel="Weekday" itemValue="Weekday" />
</p:selectManyCheckbox>
Event method:
public void onDisplayByClick() {
jsfUtils.messages("INFO", "Selected:", this.displayBy.toString());
}
First click (selecting the option) displays:
Selected: []
Second click (unselecting the option) displays:
Selected: [Weekday]