0 Replies Latest reply on Oct 28, 2010 10:25 AM by Palani swamy

    Date Validation

    Palani swamy Newbie
      <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <ui:composition xmlns="http://www.w3.org/1999/xhtml"
      xmlns:s="http://jboss.com/products/seam/taglib"
      xmlns:ui="http://java.sun.com/jsf/facelets"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:a="http://richfaces.org/a4j"
      xmlns:rich="http://richfaces.org/rich"
      template="../layout/admintemplate.xhtml">
      <ui:define name="body">
      <h:form id="productMaster" styleClass="edit" style="width:740px;">
      <rich:panel>
      <f:facet name="header">#{productMasterHome.managed ? 'Edit' : 'Add'} #{messages.lblProductMasterDetails}</f:facet>
      <table>
      <tr>
      <td colspan="3">
      <s:decorate id="productAvailableFromField" template="../layout/edit.xhtml">
      <ui:define name="label">
      <h:outputText value="#{messages.lblProductAvailableFrom}"/>
      </ui:define>
      <rich:calendar id="productAvailableFrom1" required="true" requiredMessage="Plz select From Date" value="#{productMasterHome.instance.productAvailableFrom}"
      datePattern="#{ParamUtil.DATE_PATTERN}" boundaryDatesMode="scroll">
      <a:support event="onchanged" ajaxSingle="true" reRender="productAvailableFrom1,productAvailableFromField"/>
      </rich:calendar>
      </td>
      <td>
      <ui:define name="label">
      <h:outputText value="#{messages.lblProductAvailableTo}"/>
      </ui:define>
      <rich:calendar id="productAvailableTo1" required="true" requiredMessage="Plz select To Date"
      dayStyleClass="disabledClassesProv" value="#{productMasterHome.instance.productAvailableTo}"
      datePattern="#{ParamUtil.DATE_PATTERN}" boundaryDatesMode="scroll">
      <a:support event="onchanged" ajaxSingle="true" reRender="productAvailableTo1"/>
      </rich:calendar>
      </s:decorate>
      </td>
      </tr>
      </table>
      </ui:define>
      </ui:composition>


      If i select fromdate(ex 25-10-2010)from calendar control, the ToDate Calendar Control Should be Display greater than from date (ex : >25-10-2010).

      I need a suggession for the above issue.

      Thanks in advance.