Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

selectBooleanCheckbox: ValuechangeListener runs when rendering

areyesFeb 11 2015 — edited Feb 12 2015

Hi,

I have a page with a tree (af: tree) and checks (selectBooleanCheckbox) at the nodes of the tree.

<af:tree value="#{bindings.ArbolOperadoresIncidenciasNivel2ROView1.treeModel}"

               var="node" styleClass="arbol-incidencias"

               selectionListener="#{bindings.ArbolOperadoresIncidenciasNivel2ROView1.treeModel.makeCurrent}"

               rowSelection="multiple" id="arbol_ope">

    <af:clientAttribute name="Nombre" value="#{node.Nombre}"/>

        <f:facet name="nodeStamp">

          <af:group id="g1">

            <af:switcher id="s4" facetName="#{node.TipoNodo}">

              <f:facet name="LIN">

                <af:group id="g16">

                  <af:image source="/imagenes/spacer_arbol_gris.gif"

                            shortDesc="spacer" id="image6"

                            rendered="#{node.TieneHijos == null}"

                            styleClass="capa-oculta-icono-nodo-hoja"/>

                  <af:selectBooleanCheckbox text="#{node.Nombre}"

                                            valueChangeListener="#{gestionBean.pulsarCheckBox}"

                                            autoSubmit="true" label="Label 7"

                                            value="#{node.Seleccion}"

                                            rendered="#{node.Nombre != null ? true: false}"

                                            id="sbc8"/>

                  ...



My problem is that by expanding the tree nodes function valuechangelistener runs (gestionBean.pulsarCheckBox). This function should only be executed when selected or deselected checkbox.
This makes my application is slow because the function is being executed as many times as there checkbox.


Can anybody help?


Thanks in advance

This post has been answered by DeeptiB on Feb 12 2015
Jump to Answer

Comments

Locked Post
New comments cannot be posted to this locked post.

Post Details

Locked on Mar 12 2015
Added on Feb 11 2015
13 comments
882 views