Win a copy of Node.js Design Patterns: Design and implement production-grade Node.js applications using proven patterns and techniques this week in the Server-Side JavaScript and NodeJS forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Rob Spoor
  • Tim Cooke
  • Junilu Lacar
Sheriffs:
  • Henry Wong
  • Liutauras Vilda
  • Jeanne Boyarsky
Saloon Keepers:
  • Jesse Silverman
  • Tim Holloway
  • Stephan van Hulst
  • Tim Moores
  • Carey Brown
Bartenders:
  • Al Hobbs
  • Mikalai Zaikin
  • Piet Souris

JSF with RichFaces Calendar

 
Greenhorn
Posts: 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,

I am facing a issue when i use richfaces calendar with JSF. When i have richfaces calendar in the form <h:commandButton> is not invoking the action method. When i have changed the <h:commandButton> to <a4j:commandButton>, action method is getting invoked, but all the form elements are null in the backend bean method (searchAppt) though i enter some values.

Here is the code
<h:form id="srvcPrvdrAppointmentsfrm">
<a4j:outputPanel ajaxRendered="true">
<h:inputText id="staffMember" value="#{srvcPrvdrAppointmentsBean.staffMember}"/>
<rich:calendar id="todate"
value="#{srvcPrvdrAppointmentsBean.toDate}"
datePattern="MM/dd/yyyy"></rich:calendar>
<h:outputText styleClass="usrRegParms" value="From Date"></h:outputText>
<rich:calendar id="fromdate" value="#{srvcPrvdrAppointmentsBean.fromDate}"
datePattern="MM/dd/yyyy"></rich:calendar>

<a4j:commandButton ajaxSingle="true" id="searchCmd" reRender="myAppts"
value="Search" action="#{srvcPrvdrAppointmentsBean.searchAppt}"
/>

</a4j:outputPanel>
</h:form>

I am new to richfaces and JSF. Any help will be greatly appreciated.

Jyosthna
[ April 21, 2008: Message edited by: Jyosthna Jaladi ]
 
Ranch Hand
Posts: 47
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You need to set up ajaxSingle="false" in <a4j:commandButton> UI component to submit all the form fileds to backing bean. ajaxSingle="true" prevents to submit form parameters so that you see null values in your backing bean.

Yes. you might need to use <a4j:commandButton> when you use rich faces components in the form.
 
reply
    Bookmark Topic Watch Topic
  • New Topic