java - primefaces:row edit event not working when click on pencil icon -
i using jsf,primefaces , hibernate have fetch data database inside table when click in pencil icon not working , not error or exception generated , click compiler not going on our bean class have name 1 table , client name database table working facility name column when define 2 column not working
my xhtml page
<p:datatable id="allfacilitylist" var="facility" rendered="true" value="# {facilitybean.facilitylist}" paginator="true" rows="15" paginatorposition="top" styleclass="fixed-size" emptymessage="no facility insdie faclity list" style="width: 965px;" editable="true"> <p:ajax event="rowedit" immediate="true" listener="#{facilitybean.onedit}" update=":ftlistform"/> <p:column headertext="facility name" style="width:60%; alignment-adjust: middle"> <p:celleditor> <f:facet name="output"> <h:outputtext style="alignment-adjust: middle" value="#{facility.name}" /> </f:facet> <f:facet name="input"> <p:inputtext value="#{facility.name}" style="width:100%"/> </f:facet> </p:celleditor> </p:column> <p:column headertext="client name" style="width:60%; alignment-adjust: middle"> <p:celleditor> <f:facet name="output"> <h:outputtext style="alignment-adjust: middle" value="#{facility.clientname}" /> </f:facet> <f:facet name="input"> <p:inputtext value="#{facility.clientname}" style="width:100%"/> </f:facet> </p:celleditor> </p:column>
my bean class row edit methode
public void onedit(roweditevent event) { system.out.println("onedit methode of facility bean class"); facility facility=(facility) event.getobject(); facilityservice.editfacilitylist(facility); } myservice class editfacility method public void editfacilitylist(facility facility) { int useridval = (integer) httpsession.getattribute(constants.user_id); facility.setupdateuserid(useridval); facility.setupdatedate(new date()); facilitydao.attachdirty(facility); }
Comments
Post a Comment