Julien Martin wrote:

Mathias,
You're right. I added a System.out.println in the javabean and the getter
method is never called. I am puzzled. Any clue?
Julien

Hi,

so, from one of your previous posts I assume that #{AlbumsAction.albums} returns a Map (what kind of map is unimportant), am I right??? If this is the case, it cannot work, cause the dataList has nothing to iterate over.

[code]
<x:dataList value="#{AlbumsAction.albums}" var="item"
layout="unorderedList">
  <h:column>
    <h:outputText value="#{item.value.album_date}"/>
 </h:column>
</x:dataList>
[/code]


#{AlbumsAction.albums} should either return a List of Map.Entries so you could enter the value with item.value.someproperty

Or your class AlbumsAction should return a List of the key-values like this
public List getAlbumKeys() {
return new List(albums.keySet());
}

Then you could do as follows:

<x:dataList value="#{AlbumsAction.albumKeys}" var="item" layout="unorderedList">
<h:outputText value="#{AlbumsAction.album.key.someproperty}" />
//maybe #{AlbumsAction[album][key]['someproperty']}
</x:dataList>

Regards
Alex

Reply via email to