You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

159 lines
5.7 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <openerp>
  3. <data noupdate="0">
  4. <record id="view_res_partner_changeset_tree" model="ir.ui.view">
  5. <field name="name">res.partner.changeset.tree</field>
  6. <field name="model">res.partner.changeset</field>
  7. <field name="arch" type="xml">
  8. <tree string="Partner Changeset" delete="false" create="false">
  9. <field name="partner_id"/>
  10. <field name="date"/>
  11. <field name="state"/>
  12. </tree>
  13. </field>
  14. </record>
  15. <record id="view_res_partner_changeset_form" model="ir.ui.view">
  16. <field name="name">res.partner.changeset.form</field>
  17. <field name="model">res.partner.changeset</field>
  18. <field name="arch" type="xml">
  19. <form string="Partner Changeset" delete="false" create="false">
  20. <header>
  21. <button name="apply"
  22. string="Apply pending changes" type="object"
  23. class="oe_highlight"
  24. states="draft"/>
  25. <button name="cancel"
  26. string="Reject pending changes" type="object"
  27. class="oe_highlight"
  28. states="draft"/>
  29. <field name="state" widget="statusbar"
  30. statusbar_visible="draft,done"/>
  31. </header>
  32. <sheet string="Partner Changeset">
  33. <group>
  34. <field name="partner_id"/>
  35. <field name="source"/>
  36. <field name="date"/>
  37. </group>
  38. <group string="Changes">
  39. <field name="change_ids" nolabel="1">
  40. <tree string="Partner Changeset Change">
  41. <field name="field_id" context="{'no_open': true}"/>
  42. <field name="field_type" invisible="1"/>
  43. <field name="origin_value_display" string="Previous"/>
  44. <field name="new_value_display"/>
  45. <field name="state"/>
  46. <button name="apply"
  47. string="Apply" type="object"
  48. icon="gtk-apply"
  49. states="draft"/>
  50. <button name="cancel"
  51. string="Reject" type="object"
  52. icon="gtk-close"
  53. states="draft"/>
  54. </tree>
  55. </field>
  56. </group>
  57. <group>
  58. <field name="note"/>
  59. </group>
  60. </sheet>
  61. </form>
  62. </field>
  63. </record>
  64. <record id="view_res_partner_changeset_change_form" model="ir.ui.view">
  65. <field name="name">res.partner.changeset.change.form</field>
  66. <field name="model">res.partner.changeset.change</field>
  67. <field name="arch" type="xml">
  68. <form string="Partner Changeset Change" delete="false" create="false">
  69. <header>
  70. <button name="apply"
  71. string="Apply" type="object"
  72. class="oe_highlight"
  73. states="draft"/>
  74. <button name="cancel"
  75. string="Reject" type="object"
  76. class="oe_highlight"
  77. states="draft"/>
  78. <field name="state" widget="statusbar"
  79. statusbar_visible="draft,done"/>
  80. </header>
  81. <sheet>
  82. <group>
  83. <field name="field_id" options="{'no_open': true}"/>
  84. <field name="field_type" invisible="1"/>
  85. <!-- attrs are added in fields_view_get -->
  86. <field name="origin_value_char"/>
  87. <field name="new_value_char"/>
  88. <field name="origin_value_date"/>
  89. <field name="new_value_date"/>
  90. <field name="origin_value_datetime"/>
  91. <field name="new_value_datetime"/>
  92. <field name="origin_value_float"/>
  93. <field name="new_value_float"/>
  94. <field name="origin_value_integer"/>
  95. <field name="new_value_integer"/>
  96. <field name="origin_value_text"/>
  97. <field name="new_value_text"/>
  98. <field name="origin_value_boolean"/>
  99. <field name="new_value_boolean"/>
  100. <field name="origin_value_reference"/>
  101. <field name="new_value_reference"/>
  102. </group>
  103. </sheet>
  104. </form>
  105. </field>
  106. </record>
  107. <record id="view_res_partner_changeset_search" model="ir.ui.view">
  108. <field name="name">res.partner.changeset.search</field>
  109. <field name="model">res.partner.changeset</field>
  110. <field name="arch" type="xml">
  111. <search string="Partner Changeset">
  112. <field name="partner_id"/>
  113. <filter string="Pending" name="draft"
  114. domain="[('state','=','draft')]"/>
  115. <filter string="Done" name="done"
  116. domain="[('state','=','done')]"/>
  117. <group expand="0" string="Group By">
  118. <filter string="Partner"
  119. name="groupby_partner_id"
  120. context="{'group_by': 'partner_id'}"/>
  121. <filter string="State"
  122. name="groupby_state"
  123. context="{'group_by': 'state'}"/>
  124. </group>
  125. </search>
  126. </field>
  127. </record>
  128. <record model="ir.actions.act_window" id="action_res_partner_changeset_view">
  129. <field name="name">Partner Changeset</field>
  130. <field name="type">ir.actions.act_window</field>
  131. <field name="res_model">res.partner.changeset</field>
  132. <field name="view_type">form</field>
  133. <field name="view_mode">tree,form</field>
  134. <field name="context">{'search_default_draft': 1}</field>
  135. <field name="search_view_id" ref="view_res_partner_changeset_search"/>
  136. </record>
  137. <menuitem id="menu_res_partner_changeset"
  138. parent="menu_changeset"
  139. sequence="20"
  140. name="Changesets"
  141. action="action_res_partner_changeset_view"/>
  142. </data>
  143. </openerp>