a4j:commandLink not triggering a4j:param assignment when using rich:componentControl
djheath Sep 7, 2011 12:43 AMI have an a4j:param within an a4j:commandLink that isn't making the assignment due to the additional presence of the rich:componentControl within it. Essentially I need to set the id of an object before the rich:popupPanel shows. I'm using the rich:componentControl to position the popupPanel at a specific location on the screen
Anyone run into this before? (I'm using RF 4.0). The following code is a facelet being included in an a4j:repeat (elsewhere) and without the rich:componentControl works but doesn't place the popup where I want it.
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:a4j="http://richfaces.org/a4j"
xmlns:rich="http://richfaces.org/rich"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:f="http://java.sun.com/jsf/core" xml:lang="en" lang="en">
<ui:composition >
<li>
<a4j:commandLink id="ll" render="actionbar" style="color:white;" limitRender="true">
<a4j:param name="babyId" value="#{baby.id}" assignTo="#{babyBean.id}"/> <!-- not working -->
<img src="#{baby.photoUrl}" class="marker"/>
<div class="name">#{baby.name}</div>
<a4j:outputPanel layout="block" rendered="#{not empty siteCheckedinBean.eventMap[baby.id]}"
styleClass="ribbon_#{siteCheckedinBean.eventMap[baby.id].eventType.label}" />
<rich:componentControl event="mousedown" operation="show" target="actionbar">
<a4j:param name="event" value="event" noEscape="true" />
<rich:hashParam>
<a4j:param noEscape="true" name="top"
value="jQuery(#{rich:element('ll')}.parentNode).offset().top + jQuery(#{rich:element('ll')}.parentNode).height() - 80" />
<a4j:param noEscape="true" name="left"
value="jQuery(#{rich:element('ll')}.parentNode).offset().left + 7" />
</rich:hashParam>
</rich:componentControl>
</a4j:commandLink>
</li>
</ui:composition>
</html>
Thanks in advance