【问题标题】:PrimeFaces CellEditEvent - Method not found errorPrimeFaces CellEditEvent - 找不到方法错误
【发布时间】:2014-08-24 17:38:45
【问题描述】:

[ERROR] 发生异常 javax.el.MethodNotFoundException:/partner/index.xhtml 在第 44 行和第 78 列 action="#{PartnerEdit.cellRowEdit()}":找不到方法:com.ibm.ic.partner.view.PartnerEdit@3302e49a.cellRowEdit ()

<p:ajax event="cellEdit" listener="#{PartnerEdit.cellRowEdit()}" />

@ManagedBean(name="PartnerEdit")

@ViewScoped
public class PartnerEdit implements Serializable {

public void cellRowEdit(CellEditEvent event){       
        System.out.println(event.getNewValue());        
    }

【问题讨论】:

    标签: java jsf primefaces


    【解决方案1】:
    #{PartnerEdit.cellRowEdit()}
    

    引用不带任何参数的方法。 由于您的方法实际上有一个参数,因此您需要在没有大括号的情况下引用它:

    #{PartnerEdit.cellRowEdit}
    

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-03-19
      • 1970-01-01
      • 2021-05-07
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多