Output Panel => Link doesn´t work

UI Components for JSF
Post Reply
rider
Posts: 497
Joined: 05 Mar 2010, 13:17

14 Apr 2010, 15:03

Hello,
I want to built a menu.
If I click on a link a output panel will disappear => WORK!
Now I want to click on the new link which was appear, but this link doesn´t work and the submenu will now disappear again.

So I have the problem, that the link doesn´t work and the submenu shouldn´t now disapear.
How can I fix this problem?

Code: Select all

					<div class="menu_headline">
								<p:commandLink value="Verwaltung"
										       update="verwaltung">
										       <f:setPropertyActionListener value="#{true}" target="#{requestScope.renderverwaltungSubmenue}" />  
								</p:commandLink>
					</div>

							<p:outputPanel id="verwaltung">
							<div id="submenu">			
										<ul>								   

											
											<li>
												<h:commandLink 	action="#{apv.findAllArbeitsplatz}" 
												 				class="leftnav_1"
														   		value="Alle Verwaltungen"
														   		rendered="#{requestScope.renderverwaltungSubmenue}"/>
											</li>
											
										</ul>
								</div> 
		    				</p:outputPanel>
Primefaces 12.0, WildFly 21

cagatay.civici
Prime
Posts: 18616
Joined: 05 Jan 2009, 00:21
Location: Cybertron
Contact:

18 Apr 2010, 23:52

You need to make sure, the state of requestScope.renderverwaltungSubmenue is longer than one request, for the second request, rendered will be false as requestScope has no renderverwaltungSubmenue, and JSF does not process a component if it is not rendered.

Do you use JSF 2, if so try view scope, that will fix it.

rider
Posts: 497
Joined: 05 Mar 2010, 13:17

20 Apr 2010, 10:27

have you an example, please?
Primefaces 12.0, WildFly 21

Post Reply

Return to “PrimeFaces”

  • Information
  • Who is online

    Users browsing this forum: rinzler.3x and 24 guests