日期:2014-05-20  浏览次数:20611 次

El如何获得对象集合中对象的属性
CmsCategoryCollection CmsCategoryColl = cmsCategoryService.GetListPagerBy(OrderBy, pageIndex, pageSize);
request.setAttribute("CmsCategoryList", CmsCategoryColl);

对象属性有id1,id2,id3,我如何中jsp页面中通过EL表达式获得对象的id2,还忘高手指点。


------解决方案--------------------
外面嵌套个循环接收CmsCategoryList
然后定义个别名,比如entity
用${entity.id2}得到值

------解决方案--------------------
${CmsCategoryList.id1}