here is my case:
I want to fetch area "inforContent" property 'date' at a JSP page
<c:forEach items="${model.newsList}" var="news">
<c:set var="newsInfo" value="${cmsfn:page(news)}"/>
${news.title} ${news.date}
</c:forEach>
'title' can be fetch on jsp page , but I can't fetch the property 'date'.
Is some configuration wrong?
Thanks all you guys in advance!
I dump data from JCR Queries tool with
repository:website,path:/feiyi/news-list/news1,level:2
[b]result[/b]:
/feiyi/news-list/news1/inforContent
/feiyi/news-list/news1/inforContent/[b]title[/b]=test
/feiyi/news-list/news1/inforContent/jcr:uuid=34f4905b-a357-409d-baee-8325e426747c
/feiyi/news-list/news1/inforContent/jcr:createdBy=admin
/feiyi/news-list/news1/inforContent/content=<p> test <br /> </p>
/feiyi/news-list/news1/inforContent/[b]date[/b]=2013-06-21T16:00:00.000Z
/feiyi/news-list/news1/inforContent/jcr:created=2013-06-23T14:58:01.109+08:00
/feiyi/news-list/news1/inforContent/jcr:primaryType=mgnl:area
/feiyi/news-list/news1/inforContent/author=test
/feiyi/news-list/news1/inforContent/MetaData[mgnl:metaData]
/feiyi/news-list/news1/inforContent/acticlePicIntro[mgnl:area]
/feiyi/news-list/news1/inforContent/content_files[mgnl:contentNode]
and I create a SQL , named:queryNewsListSQL:
SELECT * FROM mgnl:area WHERE jcr:path LIKE '/feiyi/news-list/%/inforContent/
Model Class Code:
newsList=new ArrayList<ContentMap>();
NodeIterator nodeIterator =QueryUtil.search(RepositoryConstants.WEBSITE,
queryNewsListSQL, Query.SQL, MgnlNodeType.NT_AREA);
while(nodeIterator.hasNext()){
newsList.add(new ContentMap(nodeIterator.nextNode()));
}
and I iterate above 'newsList', i found there is no 'date' property
key:id value:null
key:title value:test01
key:jcr:created value:java.util.GregorianCalendar
key:name
value:null
key:path
value:null
key:jcr:createdBy
value:admin
key:nodeType
value:null
key:depth
value:null
key:jcr:primaryType
value:mgnl:page
key:jcr:mixinTypes
value:[Ljava.lang.String;@18990fb
.............
--
Context is everything:
http://forum.magnolia-cms.com/forum/thread.html?threadId=42bbb54a-91e6-4fe3-8d5a-e1f7b6544fe8
----------------------------------------------------------------
For list details, see http://www.magnolia-cms.com/community/mailing-lists.html
Alternatively, use our forums: http://forum.magnolia-cms.com/
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------