5 Replies Latest reply on Nov 4, 2009 5:40 AM by Vasavi Vajinepalli

    Faces Messages have been not displayed

    Vasavi Vajinepalli Newbie
      Hi all,

      I have faced a problem that when i submit the form without entering in a field which is required n moreover its a selectOneMenu field, the faces messages have not been displayed on the browser. it is showing on the console like, 

      WARNING: FacesMessage(s) have been enqueued, but may not have been displayed.

      i have reRender the field also, but im not able to get the messages on the browser.
      Here is my code:

      <rich:modalPanel id="portEditWizard"
              minWidth="400"
              autosized="true">
               
              <f:facet name="header"><h:outputText value="Edit Port..." /></f:facet>
              <f:facet name="controls">
               <h:graphicImage value="/img/ico_close.gif"
                    styleClass="linkImage"
                       onclick="#{rich:component('portEditWizard')}.hide()" />
              </f:facet>
              
           <h:form id="portEditForm" styleClass="talign">
           
      <h:panelGrid columns="1" >
                 <s:decorate id="callIdField" template="../layout/edit.xhtml">
                      <ui:define name="label">Port Call#</ui:define>
                      <h:inputText id="callId"
                             required="true"
                                value="#{voyagePort.callId}">
                          <a:support event="onblur" reRender="callIdField" bypassUpdates="true" ajaxSingle="true"/>
                      </h:inputText>
                  </s:decorate>
                 
                  <s:decorate id="actTypeCodeField" template="../layout/edit.xhtml">
                          <ui:define name="label">ActType Code</ui:define>
                          <h:selectOneMenu value="#{voyagePort.icActivity}" required="true" id="activity">
                               <s:selectItems value="#{activities}" var="activity" label="#{activity.actTypeCode}" noSelectionLabel="select ActType"/>
                               <s:convertEntity />
                               <a4j:support event="onblur" reRender="actTypeCodeField" bypassUpdates="true" ajaxSingle="true"/>
                          </h:selectOneMenu>
                     </s:decorate>
                 
                  <s:decorate id="portCodeField" template="../layout/edit.xhtml">
                               <ui:define name="label">Port Code</ui:define>
                          <h:selectOneMenu value="#{voyagePort.icLocationByPortId}" required="true" id="portCode">
                               <s:selectItems value="#{locations}" var="port" label="#{port.locCode}" noSelectionLabel="select Port"/>
                               <s:convertEntity />
                               <a4j:support event="onblur" reRender="portCodeField" bypassUpdates="true" ajaxSingle="true"/>
                          </h:selectOneMenu>
                     </s:decorate>
                     
                     
                   <s:decorate id="FActive2Field" template="../layout/edit.xhtml">
                      <ui:define name="label">Active</ui:define>
                      <h:selectOneMenu id="FActiveField" value="#{voyagePort.FActive}"
                                           required="true">
                                  <f:selectItem id="item1" itemValue="Y" itemLabel="Yes" />
                                  <f:selectItem id="item2" itemValue="N" itemLabel="No" />
                         </h:selectOneMenu>
                          <a:support event="onblur" reRender="FActive2Field" bypassUpdates="true" ajaxSingle="true"/>
                     
                  </s:decorate>
                 
                     
      </h:panelGrid>
              
              
                
               <div class="actionButtons" style="clear:both" align="right">
         
               <a:commandButton id="portEditMPCancel1"
                 onclick="#{rich:component('portEditWizard')}.hide()"
                  action="#{itVoyagePortAction.persistPort}" 
                  rendered="#{s:hasRole(messages['com.infyz.toms.role.transportation.ocean.voyage_master.save'])}"    
                 reRender="voyagePortListTable"
                 value="Ok" />
                  &#160;
                <a:commandButton id="portEditMPCancel"
                 onclick="#{rich:component('portEditWizard')}.hide()"
                 reRender="voyagePortListTable"
                 value="Cancel" />
           
               </div>
             
              </h:form>

          </rich:modalPanel>



      I have tried using <a4j:outputPanel ajaxRendered="true"> also,but still im facing the same problem.


      Thanks in advance