解决 org.hibernate.HibernateException: Could not obtain transaction-synchronized Session for cu
在web.xml添加如下代码
<!-- 解决 org.hibernate.HibernateException: Could not obtain transaction-synchronized Session for current 出错问题 -->
<filter>
<filter-name>SpringOpenSessionInViewFilter</filter-name>
<filter-class>org.springframework.orm.hibernate4.support.OpenSessionInViewFilter</filter-class>
</filter>
<filter-mapping>
<filter-name>SpringOpenSessionInViewFilter</filter-name>
<url-pattern>/*</url-pattern>
</filter-mapping>