mapping.xml 2.7 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879
  1. <?xml version="1.0" encoding="GB2312"?>
  2. <mapping>
  3. <!--配置wcm对象的版本管理功能-->
  4. <class name="com.trs.components.wcm.version.config.ObjectVersionConfig" identity="name">
  5. <map-to xml="object-version-config"/>
  6. <!-- wcm关联对象唯一标识,在同一配置中要保证id字段唯一 -->
  7. <field name="id">
  8. <bind-xml name="id" node="attribute"/>
  9. </field>
  10. <!-- wcm对象类型 -->
  11. <field name="classname">
  12. <bind-xml name="class" node="attribute"/>
  13. </field>
  14. <!-- wcm对象描述 -->
  15. <field name="desc">
  16. <bind-xml name="desc" node="attribute"/>
  17. </field>
  18. <!-- 权限值 -->
  19. <field name="right">
  20. <bind-xml name="right" node="attribute"/>
  21. </field>
  22. <!-- wcm对象在版本管理标题栏的标题名称(如:文字库document的版本管理界面文档标题) -->
  23. <field name="titledesc">
  24. <bind-xml name="title-desc" node="element"/>
  25. </field>
  26. <!-- 是否开启版本管理功能 -->
  27. <field name="build" type="boolean">
  28. <bind-xml name="version-build" node="element"/>
  29. </field>
  30. <!-- 对象版本管理的排除字段(字段以“,”隔开) -->
  31. <field name="excludefields">
  32. <bind-xml name="excludefields" node="element"/>
  33. </field>
  34. <!-- 可以保留的最大版本数,超过最大版本数后会删除最旧的版本 -->
  35. <field name="MaximumVersion" type="integer">
  36. <bind-xml name="max-version" node="element"/>
  37. </field>
  38. <!-- 关联表对象 -->
  39. <field name="relations" collection="map">
  40. <bind-xml name="relation-object">
  41. <class name="org.exolab.castor.mapping.MapItem">
  42. <!-- 主表的关联字段,命名格式(多级关联用“.”隔开), -->
  43. <field name="key">
  44. <bind-xml name="key" node="attribute" />
  45. </field>
  46. <!-- 关联对象信息 -->
  47. <field name="value" type="com.trs.components.wcm.version.config.RelationObjectVersionConfig">
  48. <bind-xml name="value" node="element"/>
  49. </field>
  50. </class>
  51. </bind-xml>
  52. </field>
  53. </class>
  54. <!-- 版本管理关联对象配置文件 -->
  55. <class name="com.trs.components.wcm.version.config.RelationObjectVersionConfig" identity="name">
  56. <map-to xml="object"/>
  57. <!-- wcm对象类型 (此为对象集合,可能存在一对多的映射) -->
  58. <field name="classname">
  59. <bind-xml name="class" node="attribute"/>
  60. </field>
  61. <!-- wcm关联对象唯一标识,在同一配置中要保证id字段唯一 -->
  62. <field name="id">
  63. <bind-xml name="id" node="attribute"/>
  64. </field>
  65. <!-- wcm对象描述 -->
  66. <field name="desc">
  67. <bind-xml name="desc" node="attribute"/>
  68. </field>
  69. <!-- 对象版本管理的排除字段(字段以“,”隔开) -->
  70. <field name="excludefields">
  71. <bind-xml name="excludefields" node="element"/>
  72. </field>
  73. <!-- 关联表与主表的关联字段 -->
  74. <field name="relationkey">
  75. <bind-xml name="relationkey" node="element"/>
  76. </field>
  77. </class>
  78. </mapping>