No ajax when selecting null + required need a null value

UI Components for JSF
Post Reply
frioux
Posts: 21
Joined: 02 Nov 2015, 23:32

14 May 2019, 20:13

Hi,

I'm trying to do something that should be easy, but no luck.

Code: Select all

<p:selectOneMenu id="selectQuestionnaryERGType" value="#{ergBean.selectedQuestionnaryERGTypeId}" required="true" requiredMessage="#{bundle['validation.upload.questionnaire']}">
	<p:ajax update="XXX"/>
	<f:selectItem itemLabel="#{bundle['selectNoSelection']}" itemValue="#{null}"/>
	<f:selectItems value="#{ergBean.getERGQuestionnaries(editVisitBean.editSubjectVisit)}" var="q" itemLabel="#{q.name} (#{q.version})" itemValue="#{q.idQuestionary}"/>
</p:selectOneMenu>
I am not able to have an ajax update when null is selected, work nice on other options and if I change the option to something else then required will not work. Please advise a solution, thanks you.

Primefaces 6.2

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: No registered users and 34 guests