2 Replies Latest reply on Feb 27, 2009 10:07 AM by Tsikhon Kuprevich

    Rich:suggestionbox onselect problem

    L SM Newbie

      The onselect is working fine at normal situation. But it has a bug when the suggestion box is being change from rendered=false to rendered=true.

      i: the rich:suggestionbox will display the old selections that generated last time. (solved by adding the a4j:support to reRender the rich:suggestionbox when clicking the target textfield)

      ii. For example: i type "app" which got 3 selections in rich:suggestionbox apple, application and applicant. There is some space at the bottom of selection items in the rich:suggestionbox, if i click onside, it would trigger the onselect event and close the rich:suggestionbox, textfield would contain only "app" which is not a valid selection.

        • 1. Re: Rich:suggestionbox onselect problem
          Aleksandr Dubovsky Newbie

          Hello,

          I could not reproduce your problem using following code:

          <h:form>
           <h:selectBooleanCheckbox value="#{sBox.rendered}">
           <a4j:support event="onclick" reRender="sb"></a4j:support>
           </h:selectBooleanCheckbox>
           <h:panelGrid id="sb" columns="1">
           <h:inputText id="text" value="#{sBox.value}" />
           <rich:suggestionbox height="300" width="200" for="text"
           rendered="#{sBox.rendered}"
           suggestionAction="#{sBox.suggestionAction}" var="row"
           fetchValue="#{row.make}" onselect="alert('onselect')">
           <rich:column>
           <h:outputText value="#{row.make}" />
           </rich:column>
           </rich:suggestionbox>
           </h:panelGrid>
           </h:form>


          Could you please describe your environment and post your sources.

          • 2. Re: Rich:suggestionbox onselect problem
            Tsikhon Kuprevich Newbie

            Hi,

            could you please describe uoyr cases more exactly? Code samples would be perfect. Because it looks fine to me, as far as I understand.

            Thanks for your time!

            Best Regards,
            Tsikhon Kuprevich