Jsf 异常EL表达式不平衡:
我在我的web应用程序中使用JSF。我将参数从我的复合组件传递到bean,但我得到了EL表达式不平衡异常。下面是我试图使用的代码Jsf 异常EL表达式不平衡:,jsf,jsf-2,primefaces,Jsf,Jsf 2,Primefaces,我在我的web应用程序中使用JSF。我将参数从我的复合组件传递到bean,但我得到了EL表达式不平衡异常。下面是我试图使用的代码 <h:panelGroup binding="#{datatableManagedBean.getDynamicDataTableGroup(#{cc.attrs.id})"/> 但我正在变得异常 javax.el.ELException: EL Expression Unbalanced: ... #{datatableManagedBean.ge
<h:panelGroup binding="#{datatableManagedBean.getDynamicDataTableGroup(#{cc.attrs.id})"/>
但我正在变得异常
javax.el.ELException: EL Expression Unbalanced: ... #{datatableManagedBean.getDynamicDataTableGroup(#{cc.attrs.id})
at com.sun.faces.facelets.el.ELText.findVarLength(ELText.java:476)
at com.sun.faces.facelets.el.ELText.parse(ELText.java:396)
at com.sun.faces.facelets.el.ELText.parse(ELText.java:347)
at com.sun.faces.facelets.el.ELText.parse(ELText.java:338)
at com.sun.faces.facelets.el.ELText.isLiteral(ELText.java:321)
at com.sun.faces.facelets.tag.TagAttributeImpl.<init>(TagAttributeImpl.java:127)
javax.el.ELException:el表达式不平衡:#{datatableManagedBean.getDynamicDataTableGroup(#{cc.attrs.id})
在com.sun.faces.facelets.el.ELText.findVarLength(ELText.java:476)上
位于com.sun.faces.facelets.el.ELText.parse(ELText.java:396)
位于com.sun.faces.facelets.el.ELText.parse(ELText.java:347)
位于com.sun.faces.facelets.el.ELText.parse(ELText.java:338)
位于com.sun.faces.facelets.el.ELText.isLiteral(ELText.java:321)
位于com.sun.faces.facelets.tag.TagAttributeImpl.(TagAttributeImpl.java:127)
Ant的帮助将非常有用。提前感谢。不要在另一个EL中使用EL表达式,您还忘记关闭第一个EL 使用此选项并注意差异
#{datatableManagedBean.getDynamicDataTableGroup(cc.attrs.id)}
即使缺少“}”也会记录错误。比如:
<c:forEach items="#{customerRegistrationBean.accountWebData.selectedAccount" var="account">
...
...
Daniel:如果在另一个EL中使用EL表达式不是正确的方法,是否还有其他方法可以实现它。我不确定您想要实现什么,但您应该用{myBean.myMethod(someVar)}来包装整个EL表达式
其中someVar
可以从内部获取ui:repeat
/h:datatable
/ui:param
/someOtherBean.someOtherValue
/etc。。。