java获取model的值,springmvcmodel存值页⾯取值有关问题
阳有几笔画
springmvc model存值页⾯取值问题
本帖最后由 u014490157 于 2014-06-12 11:04:25 编辑
事情是这样的:后台从数据库取出来⼀个集合存到model,在页⾯⽤jstl取不出来,详细代码如下
后台代码
public String getMeetingList(Model model){
List meetingList;
会计题目try {
String path = getClassPath("Meeting");
meetingList = meetingDao.query(Class.forName(path));
model.addAttribute("meetingList",meetingList);逸闻趣事
System.out.(0).toString());//控制台结果是del.Meeting@d5b453永不言败
} catch (ClassNotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
return "redirect:/page/home.jsp";
}
页⾯代码
${mt.mtName}${mt.mtState}${mt.mtStartData}${mt.mtEndData}${mt.mtPlace}${mt.mtPostil}${mt.mtScheDule}${mt.mtBackGround}${mt.mtLogistics}实体类
private long mtId;
private String mtName;
徒步穿越
private String mtState;
private Date mtStartData;
private Date mtEndData;与动物有关的作文
private String mtPlace;竹笋炒肉片
private String mtPostil;
private String mtScheDule;出差标准
private String mtBackGround;
private String mtLogistics;
private List MtUrList;
页⾯输出发现是空的,请问这个是怎么回事
------解决⽅案--------------------
redirect啦,当然请求不到了!