I have a backing bean containing this object:
List<Session> sessions;and a Session is an class that has some standard fields but also this:
List<Entry> entries;An Entry is a class that contains several fields but all of them standard java objects.
So it's like this.. List<Session> |-Session |-List<Entr开发者_C百科y> |-Entry
I have tried accessing the List<Entry> directly with success.
But when I try to access the List<Session> I get the following error:javax.faces.FacesException: javax.el.PropertyNotFoundException: /pages/console.jspx @75,109 value="#{session.sessionID}": The class 'org.apache.cata lina.session.StandardSessionFacade' does not have the property 'sessionID'.
(sessionID is a String field of Session class)
Is there any way to fix this ?? (could a converter solve this ?)
the jspx code is:
<rich:dataOrderedList id="sessions" var="session" value="#{backEnd.sessions}" style="position:relative;top:40px">
<rich:togglePanel switchType="client" stateOrder="closed, opened" initialState="#{backEnd.sessionsState}">
<f:facet name="closed">
<rich:toggleControl style="font-weight:bold;" value="#{session.sessionID}" switchToState="opened" />
</f:facet>
Thanks in advance !!You are using 'session' keyword as a variable and it seems like there is another bean named 'session'. To solve the problem, change your var property. Use something like
<rich:dataOrderedList id="sessions" var="mySession" value="#{backEnd.sessions}" style="position:relative;top:40px">
instead of
<rich:dataOrderedList id="sessions" var="session" value="#{backEnd.sessions}" style="position:relative;top:40px">
It appears the problem had nothing to do with code, config, deploy or anything related to that.
There is a meta parameter in the header of html documents called "Pragma" and it is used by the browsers to cache pages for the back/forward navigation. Maybe for refresh too because this was my case. (clearing cache on firefox had no effect).
So if you want to fix this while developing there is a firefox addon called "Modify Headers" which allows you to include parameters in the headers of the requested websites.
If you want to remove this feature from your html for some reason you have to add the following in the header:
<META HTTP-EQUIV="Pragma" CONTENT="no-cache">
<META HTTP-EQUIV="Expires" CONTENT="-1">
and I haven't investigated this one which may be needed as well:
<META HTTP-EQUIV="Cache-control" CONTENT="no-cache">
精彩评论