第一次配置opensessioninview。。写下来。。

来源:互联网 发布:数据新闻报道 编辑:程序博客网 时间:2024/05/20 00:51

首先web.xml加入

我的applicationContext.xml文件。。

 

查询什么的用getHibernateTemplate().find。。

 

 

好像在struts配置文件用plug-in加载,初始化spring的是用不了OpenSessionInView的。我一直没有时间去研究怎么解决这个,我就直接在web.xml里加载的spring配置文件。

原创粉丝点击