5 Replies Latest reply on Feb 16, 2016 6:24 AM by michpetrov

    rich:tab "Value" Name attribute is missing in the RF 4.5.13??

    sivaprasad9394

      Hello,

       

      What is the equivalent Name Attribute for the Value as like in the RF 4.5.13??

       

      valuefalsejava.lang.ObjectThe current value of this component.

      Why this is removed?

      I have a problem in setting the Right Tab selected after ActionListener call.

      But i have already given,

      <rich:tabPanel id="results" switchType="client"

                  activeItem="#{reporting.selectedTab}">

      IF value is available for <rich:tab then I would have set value as value="#{reporting.selectedTab}".

      What is the alternate for Value in latest version of RF?

      RF-4.5.13.png

       

      I am trying to select the Second Tab Recursive Reporting Tab via DataTable Column Row via Rich:context menu CommandLink click.This is not happening even after rendering the @form.

      1.For selection of the Second tab in Earlier version of the RF has <rich:tab>,where i can set the value from back end bean.

      2.Even now i have

      <rich:tabPanel id="results" switchType="client"

                  activeItem="#{reporting.selectedTab}">

      3.After clicking the context menu link from data table ,It should select the second tab automatically.This is not happening.

       

      Thank you.

        • 1. Re: rich:tab "Value" Name attribute is missing in the RF 4.5.13??
          michpetrov

          Please shorten the example, don't show components if they're not important (http://sscce.org). You can also use syntax highlighting if you switch to the advanced editor (top right corner of the reply window). Secondly nested forms are not valid, get rid of them.

           

          Now, the value attribute is inherited from UICommand, the class behind h:commandButton (where value = text on the button), it's not used on rich:tab. Could you explain what you're trying to do?

          • 2. Re: rich:tab "Value" Name attribute is missing in the RF 4.5.13??
            sivaprasad9394

            Hello Petrov,

            I am trying to select the Second Tab Recursive Reporting Tab via DataTable Column Row via Rich:context menu CommandLink click.This is not happening even after rendering the @form.

            1.For selection of the Second tab in Earlier version of the RF has <rich:tab>,where i can set the value from back end bean.

            2.Even now i have

            <rich:tabPanel id="results" switchType="client"

                        activeItem="#{reporting.selectedTab}">

            3.After clicking the context menu link from data table ,It should select the second tab automatically.This is not happening.

            Thank you.

            • 3. Re: rich:tab "Value" Name attribute is missing in the RF 4.5.13??
              michpetrov

              You just need to set the @activeItem to the correct value (i.e. @name of the rich:tab you want to switch to), if you're not doing any AJAX updates you can switch with JavaScript - RichFaces.component("form:tabPanel").switchToItem("tabName")

              • 4. Re: rich:tab "Value" Name attribute is missing in the RF 4.5.13??
                sivaprasad9394

                I have resolved the issue by implementing the oncomplete as like below in commandLink,

                xhtml page:

                <rich:menuItem>

                                     <a4j:commandLink id="siReportButton2"  

                                        action="#{reporting.setRb_countername(_data.counterName.counterName)}"

                                        value="#{messages.gotobreadcrumb}" data="#{_data.counterName.shortid.shortid}"

                                        actionListener="#{reporting.setFocusedShortIdActionListener}"

                                        oncomplete="selectshortIdSearch();"

                                        render="results" limitRender="true" execute="@form">

                                        <f:setPropertyActionListener value="breadCrumbSearch" for="siReportButton2"

                                            target="#{reporting.selectedTab}" />

                                    </a4j:commandLink>                   

                                </rich:menuItem>

                JavaScript:

                function selectshortIdSearch() {

                          RichFaces.component("results").switchToItem("breadCrumbSearch");

                  }

                Thank you.

                • 5. Re: rich:tab "Value" Name attribute is missing in the RF 4.5.13??
                  michpetrov

                  Glad you got it working, I'm looking into why it doesn't work by changing the bean property directly (it works you call resetValue() on the UITabPanel but that shouldn't be necessary)