您的位置:首页 > Web前端 > JavaScript

Jsp页面中ajax提交数据:及hbm.xml文件中出现的错误

2010-11-27 21:46 537 查看
从jqgrid获得数据dele(”+rowObject.uid+”)
Function dele(id)中传入的数据要用data包裹,另外action里的数据id要和
Data里面传入的一样。此外,action里 的方法中不要写参数
一般通过get set得到ajax提交的data数据。



当 名称不一样时会报如下错误



另外,Hbm.xml文件映射中 不能出现空格,否则出现如下错误:
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in class path resource [spring/applicationContext.xml]: Invocation of init method failed; nested exception is org.hibernate.InvalidMappingException: Could not parse mapping document from file D:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/erp/WEB-INF/classes/hibernate/
 
Caused by: org.hibernate.InvalidMappingException: Could not parse mapping document from file D:/workspace/.metadata/.plugins/org.eclipse.wst.server.core/tmp0/wtpwebapps/erp/WEB-INF/classes/hibernate
 
Caused by: org.hibernate.PropertyNotFoundException: field [taskassigdate ] not found on
 
 
Hbm.xml文件映射中 不能处理集合类型 当entity类中有集合类型的的属性时,汇报如下错误:
严重: Exception sending context initialized event to listener instance of class org.springframework.web.context.ContextLoaderListener
Caused by: org.hibernate.MappingException: Could not determine type for: java.util.List, at table:
如果坚持要放集合,则需将集合独立成一张表,在hbm.xml文件中建立对映关系(多对一,多对多等)。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签:  ajax jsp action
相关文章推荐