the parameters are set by
<ui:param name="p_entity" value="#{ ...
However, I've added a <p:dialog> with a <p:commandButton>, and for some reason the actionListener attribute can't resolve p_entity, so I have to write it explicity like this: actionListener="#{whiteListFriendsAndFamily.deleteItems}"
In the same scope, I have a <p:dataList> which does resolve using the parameter eg value="#{p_entity.selectedItems}" var="selected">
So why the difference ? A bug, or am I missing something ?
Here is the outline of my ui:composition, with section removed.
Code: Select all
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:f="http://java.sun.com/jsf/core"
xmlns:h="http://java.sun.com/jsf/html"
xmlns:ui="http://java.sun.com/jsf/facelets"
xmlns:p="http://primefaces.prime.com.tr/ui"
>
...
<p:dialog header="Delete these items ?" widgetVar="deleteDialog"
width="400" height="400" showEffect="explode" hideEffect="explode">
<p:dataList id="displayMulti"
value="#{p_entity.selectedItems}" var="selected">
Model: #{selected.description}
</p:dataList>
<p:commandButton value="Delete" update="growl"
actionListener="#{whiteListFriendsAndFamily.deleteItems}"
oncomplete="deleteDialog.hide();"
/>
</p:dialog>
</ui:composition>