xautlx / s2jh

A Java/J2EE development framework for enterprise system based on Struts/Spring/JPA/Hibernate and jquery/bootstrap
GNU Lesser General Public License v3.0
321 stars 242 forks source link

行内新增记录时报错:该数据已被关联使用,请求的操作无效。若有疑问请联系系统管理员。 #56

Closed flanliulf closed 10 years ago

flanliulf commented 10 years ago

主要涉及业务逻辑类有两个,材料分类MaterialType 和材料Material,材料和分类是多对一的关系,在材料Entity类上维护单向多对一的关联关系。 材料 Entity: qq20140524-1 分类 Entity: qq20140524-2 material-inputBasic.jsp qq20140524-3 qq20140524-4 MaterialTypeController.java qq20140524-5

xautlx commented 10 years ago

请提供相关操作流程描述和截图说明

flanliulf commented 10 years ago

已找到原因,是Material中定义的MaterialType原来也叫parent,和MaterialType中自身的parent重名引起的