2012-07-19 56 views
0

我收到錯誤,如果我給& &條件在打開。任何人都可以糾正我。如果我在打開的simpleTogglePanel中給出&&條件,我會收到錯誤。任何人都可以糾正我

<rich:simpleTogglePanel label="Search Criteria" id="searchToggle" 
      opened="#{viewScope.searchAction.soSCPanel && viewScope.resetAction.soSCpanel}" switchType="client" 
      style="text-align:left; width:955px;*width:955px"> 

我得到下面的錯誤,我試着用「和」操作,但在這種情況下,這兩個條件不能正常工作。

com.sun.facelets.FaceletException:解析/jsp/mass/ship/search.xhtml時出錯:跟蹤的錯誤[line:42]實體名稱必須緊跟在實體引用中的'&'後面。 at com.sun.facelets.compiler.SAXCompiler.doCompile(SAXCompiler.java:234) at com.sun.facelets.compiler.Compiler.compile(Compiler.java:105) at com.sun.facelets.impl。 DefaultFaceletFactory.createFacelet(DefaultFaceletFactory.java:197) at com.sun.facelets.impl.DefaultFaceletFactory.getFacelet(DefaultFaceletFactory.java:144) at com.sun.facelets.impl.DefaultFacelet.include(DefaultFacelet.java:293) 截斷。查看日誌文件的完整的堆棧跟蹤

回答

0

你可以把和條件這樣

<rich:simpleTogglePanel label="Search Criteria" id="searchToggle" 
     opened="#{viewScope.searchAction.soSCPanel and viewScope.resetAction.soSCpanel}" switchType="client" 
     style="text-align:left; width:955px;*width:955px"> 

因此,這些變化將是「和」,而不是「& &」好像邏輯& &和||不會被jsf EL(表達式語言)解釋。

退房這個環節將是有益的:)

https://community.jboss.org/thread/187242

相關問題