java - How to set a PropertyActionListener in a <p:datatable> -


i use primefaces , want set action listner on selected row show 1 of column in dialog.

my datatable this:

<p:datatable var="ligne" value="#{detailgrillebean.lignes}">               <p:column headertext="question">                   <h:outputtext value="#{ligne.questionbs}" />               </p:column>               <p:column headertext="note">                                      <p:rating value="#{ligne.reponse}" readonly="true" />               </p:column>               <p:column headertext="justification">                   <p:commandlink  oncomplete="ndialog.show();" title="view detail" >                       <f:setpropertyactionlistener value="#{ligne}"                           target="#{detailgrillebean.selectligne}" />                     <h:outputtext styleclass="ui-icon ui-icon-search" style="margin:0 auto;" "/>                   </p:commandlink>              </p:column>           </p:datatable>  

the dialog :

       <p:dialog   hideeffect="fade" width="600" height="100" id="dialogdesc"  widgetvar="ndialog" modal="true" showeffect="fade" closable="true" appendtobody="true">               <p:outputpanel id="ndetail" style="text-align:center;">                   <h:panelgrid  columns="2" cellpadding="5">                       <h:outputtext id="type" value="#{detailgrillebean.selectligne.justification}" />                   </h:panelgrid>               </p:outputpanel>           </p:dialog>  

the backingbean:

@managedbean @requestscoped public class detailgrillebean implements serializable {  grille grille; list<lignegrille> lignes; lignegrille selectligne; //getters & setters 

when running dilog, don't show anything. tried put logging in setter , getter of selectedligne property, output log last element of lignes;

ps: i'm using primefaces 3.5 / tomcat ee 1.6

you have update dialog content. i.e. set update=":ndetail" (id depends on dialog placed) on commandbutton.


Comments

Popular posts from this blog

Android layout hidden on keyboard show -

google app engine - 403 Forbidden POST - Flask WTForms -

c - Why would PK11_GenerateRandom() return an error -8023? -