Details
-
Bug
-
Status: Closed
-
Minor
-
Resolution: Won't Fix
-
2.0.7
-
None
-
None
-
Java 7, JBoss AS 7.1.3, Primefaces 4.0
Description
The bean validation displays the error-message twice, if it validates a Primefaces-SelectOneMenu and a @NotNull annotation is present on the property.
@NotNull private String selectedItemP; @NotNull private String selectedItemH;
<h:outputLabel for="pf" value="SelectMenue PF" /> <p:selectOneMenu id="pf" value="#{validationBean.selectedItemP}"> <f:selectItem itemLabel=" no selection " noSelectionOption="true" /> <f:selectItems value="#{validationBean.items}" /> </p:selectOneMenu> <h:outputLabel for="jsf" value="SelectMenue JSF" /> <h:selectOneMenu id="jsf" value="#{validationBean.selectedItemH}"> <f:selectItem itemLabel=" no selection " noSelectionOption="true"/> <f:selectItems value="#{validationBean.items}" /> </h:selectOneMenu>
This behaviour does not occur using the JSF-SelectOneMenu and also if the PF-Menu is replaced with a PF-InputText.
In those cases the validation displays only one error message.