Note that there are some explanatory texts on larger screens.

plurals
  1. POCascade dynamic rendering selectOneMenu doesn't work
    primarykey
    data
    text
    <p>My problem I thougth is simple but I can't find a clear solution.</p> <p>I have three selectOneMenu, and I want that the first one is always rendered, the second one is rendered if the first one has some value selected and the third one is rendered if the second has some value selected.</p> <p>The relation between the first one and the second works well, but doesn't work between the second and the third.</p> <p>When I change the value for the first selectOneMenu the second selectOneMenu is diplayed or hidden correctly. But when I change the value for the second nothing happened to the third selectOneMenu, like if the f:ajax render isn't fired.</p> <p>Bellow the jsf code:</p> <pre><code>&lt;h:panelGrid columns="2"&gt; &lt;h:outputText value="Type Paiement" /&gt; &lt;h:selectOneMenu value="#{employeurBean.idTypePaiement}"&gt; &lt;f:selectItem itemValue="" itemLabel="Choix typePaiement" /&gt; &lt;f:selectItems value="#{typePaiementBean.typesPaiement}" var="vtp" itemLabel="#{vtp.libelle}" itemValue="#{vtp.idTypePaiement}" /&gt; &lt;f:ajax event="change" render="gmodp" /&gt; &lt;/h:selectOneMenu&gt; &lt;/h:panelGrid&gt; &lt;h:panelGrid id="gmodp"&gt; &lt;h:panelGroup rendered="#{employeurBean.idTypePaiement == 2}"&gt; &lt;h:outputText value="Mode Paiement" /&gt; &lt;h:selectOneMenu value="#{employeurBean.idModePaiement}"&gt; &lt;f:selectItem itemValue="" itemLabel="Choix mode Paiement" /&gt; &lt;f:selectItems value="#{modePaiementBean.modesPaiement}" var="vmp" itemLabel="#{vmp.libelle}" itemValue="#{vmp.idModePaiement}" /&gt; &lt;f:ajax event="change" render="grib"/&gt; &lt;/h:selectOneMenu&gt; &lt;/h:panelGroup&gt; &lt;/h:panelGrid&gt; &lt;h:panelGrid id="grib"&gt; &lt;h:panelGroup rendered="#{employeurBean.idModePaiement == 1}"&gt; &lt;h:outputText value="Compte" /&gt; &lt;h:inputText value="#{employeurBean.compte}"&gt; &lt;/h:inputText&gt; &lt;/h:panelGroup&gt; &lt;/h:panelGrid&gt; </code></pre> <p>Is there any idea to achieve that. Many thanks for your help</p>
    singulars
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload