BasePunishmentSection.hbm.xml 1.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. <?xml version="1.0"?>
  2. <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN"
  3. "http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd">
  4. <!-- Generated 2014-10-25 18:40:29 by Hibernate Tools 4.0.0 -->
  5. <hibernate-mapping>
  6. <class name="com.base.model.BasePunishmentSection" table="base_punishment_section">
  7. <id name="punishmentId" type="long">
  8. <column name="punishment_id" />
  9. <generator class="native" />
  10. </id>
  11. <property name="sectionType" type="string">
  12. <column name="section_type" length="10" />
  13. </property>
  14. <property name="status" type="string">
  15. <column name="status" length="10" />
  16. </property>
  17. <property name="remark" type="string">
  18. <column name="remark" length="10" />
  19. </property>
  20. <!-- <property name="createrId" type="java.lang.Long"> -->
  21. <!-- <column name="creater_id" /> -->
  22. <!-- </property> -->
  23. <many-to-one name="creater" class="com.popedom.model.PopUser" not-null="false">
  24. <column name="userId"/>
  25. </many-to-one>
  26. <property name="createTime" type="date">
  27. <column name="create_time" length="10" />
  28. </property>
  29. <!-- <many-to-one name="userType" class="com.base.model.BaseUserType" not-null="false"> -->
  30. <!-- <column name="user_type_id"/> -->
  31. <!-- </many-to-one> -->
  32. <!-- <property name="userTypeId" type="long"> -->
  33. <!-- <column name="user_type_id" not-null="true" /> -->
  34. <!-- </property> -->
  35. <set name="baseSections" cascade="all-delete-orphan" inverse="true">
  36. <key column="punishment_id"/>
  37. <one-to-many class="com.base.model.BaseSection"/>
  38. </set>
  39. <property name="userType" column="user_type" />
  40. </class>
  41. </hibernate-mapping>