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.

75 lines
3.1 KiB

  1. <?xml version="1.0"?>
  2. <odoo>
  3. <!-- Agreement Appendix List View-->
  4. <record model="ir.ui.view" id="agreement_appendix_tree">
  5. <field name="name">Agreement Appendix Tree</field>
  6. <field name="model">agreement.appendix</field>
  7. <field name="arch" type="xml">
  8. <tree string="Appendices" default_order='agreement_id, sequence'>
  9. <field name="sequence" widget="handle"/>
  10. <field name="name"/>
  11. <field name="title"/>
  12. <field name="agreement_id"/>
  13. <field name="active" invisible="1"/>
  14. </tree>
  15. </field>
  16. </record>
  17. <!-- Agreement Appendix Form View -->
  18. <record model="ir.ui.view" id="agreement_appendix_form">
  19. <field name="name">Agreement Appendix Form</field>
  20. <field name="model">agreement.appendix</field>
  21. <field name="arch" type="xml">
  22. <form string="Appendix">
  23. <sheet>
  24. <div class="oe_button_box" name="button_box">
  25. <button name="toggle_active" type="object" class="oe_stat_button" icon="fa-archive">
  26. <field name="active" widget="boolean_button" options="{&quot;terminology&quot;: &quot;archive&quot;}"/>
  27. </button>
  28. </div>
  29. <div class="oe_title">
  30. <label for="name" class="oe_edit_only"/>
  31. <h1><field name="name"/></h1>
  32. </div>
  33. <group>
  34. <group>
  35. <field name="title"/>
  36. <field name="agreement_id"/>
  37. </group>
  38. <group>
  39. <field name="sequence"/>
  40. </group>
  41. </group>
  42. <field name="content" widget="html"/>
  43. <div class="oe_edit_only">
  44. <p>
  45. For dynamic content use mako expression '${expression}'. For ex:
  46. 1. object's field name: ${object.field_name} or
  47. 2. many2one field name: ${object.many2one_field_id.field_name}
  48. </p>
  49. </div>
  50. </sheet>
  51. </form>
  52. </field>
  53. </record>
  54. <!-- Agreement Appendix Search View -->
  55. <record model="ir.ui.view" id="agreement_appendix_search">
  56. <field name="name">Agreement Appendix Search</field>
  57. <field name="model">agreement.appendix</field>
  58. <field name="arch" type="xml">
  59. <search>
  60. <filter name="group_agreement" icon="terp-partner" context="{'group_by':'agreement_id'}"/>
  61. </search>
  62. </field>
  63. </record>
  64. <!-- Actions opening views on models -->
  65. <record model="ir.actions.act_window" id="agreement_appendix_action">
  66. <field name="name">Appendices</field>
  67. <field name="res_model">agreement.appendix</field>
  68. <field name="view_mode">tree,form</field>
  69. </record>
  70. </odoo>