Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Primefaces rowselect event doesnt work in ver 3.3

Tags:

primefaces

I have this code. It should fire rowSelect event, after the user select a row and close the dialog box. it worked fine before i updated to primfaces 3.3(I had ver3.2). I dont have any exception in console and when I debuged i see the method doesnt call. I dont know where to begin to solv this problem. Could someone help me with this?

<p:dialog id="dlg" closable="true" header="New reciever" widgetVar="receiverListDlg" visible="false" modal="true">
        <p:dataTable var="reciever" value="#{transactionController.recieverList}">
            <p:ajax event="rowSelect" listener="#{transactionController.onRowSelect}" update=":form" onsuccess="receiverListDlg.hide()" />
            <f:facet name="header">  
            Previouse recievers for #{customer.firstName}   
        </f:facet>
            <p:column selectionMode="single" />

            <p:column headerText="#{msg.havale_customer_firstname}">
                <h:outputText value="#{reciever.firstName}" />
            </p:column>

            <p:column headerText="#{msg.havale_customer_lastName}">
                <h:outputText value="#{reciever.lastName}" />
            </p:column>

            <p:column headerText="#{msg.havale_customer_phoneNr}">
                <h:outputText value="#{reciever.phoneNr}" />
            </p:column>

        </p:dataTable>
    </p:dialog> 
like image 544
mettok Avatar asked Jun 07 '12 10:06

mettok


2 Answers

Now Primefaces provided some new ajax events:

  • onSelectCheckBox
  • onUnselectCheckbox
  • onSelectRadio

So rowSelect and rowUnselect will not be fired in your case.

like image 112
Zhuming Dong Avatar answered Dec 17 '22 02:12

Zhuming Dong


I think you should use the "rowSelectRadio" ajax event.

like image 31
djmj Avatar answered Dec 17 '22 01:12

djmj