2 Replies Latest reply on Jan 18, 2011 9:14 AM by R O

    status for  <rich:suggestionbox component

    cnu vas Newbie

      Hi I have recently moved to richfaces this seems to be very good work by the richfaces team and support community. Thankyou.

       

      With respect to <rich:suggestionbox>  the suggestionAction is fetching values from database and these values are taking a litte time.

      Is there a way show a status icon or status text for th rich:suggestionbox so the user while typing doesnt need to wait and wonder why the results are not showing up in the popup box.

       

      I tried with a4j:status but since the focus is lost the popup box is not shown. Any ideas on how to achieve this..?

        • 1. Re: status for  <rich:suggestionbox component
          cnu vas Newbie

          I have acheived the above said functionality like this.

          Since this suggestion box is happening inside a modal panel i have decided to show the text rather than another modal panel for the status.

           

          <rich:suggestionbox id="suggestionBox" for="actN" ajaxSingle="true"
                                  fetchValue="#{act.Num}"
                                  suggestionAction="#{richBean.autoComplete}" var="acc" minChars="3"
                                  height="200" width="200" status="searchStatus">
                                  <h:column>
                                      <h:outputText value="#{acc.accountNum}" />
                                  </h:column>
                                  <h:column>
                                      <h:outputText value="#{acc.accountName}" />
                                  </h:column>
                                  <a4j:support event="onselect" ajaxSingle="true"  reRender="acctName" >
                                         <t:updateActionListener value="#{acc.accountName}" property="#{richBean.currentItem.accountName}"/>
                                  </a4j:support>
          </rich:suggestionbox>
          <a4j:status id ="searchStatus"  forceId="true" startText="Searching...."  startStyle="color:green;font: bold 8pt arial"/>

          • 2. status for  <rich:suggestionbox component
            R O Newbie

            Thanks Srini,  This was very helpful.

            This problem already has a jirra

            https://issues.jboss.org/browse/RF-8000