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.

124 lines
6.4 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <openerp>
  3. <data>
  4. <record id="view_partner_form_easy_my_coop" model="ir.ui.view">
  5. <field name="name">res.partner.form.easy_my_coop</field>
  6. <field name="model">res.partner</field>
  7. <field name="inherit_id" ref="base.view_partner_form"/>
  8. <field name="arch" type="xml">
  9. <sheet position="before">
  10. <header>
  11. <button string="Create Subscription" name="%(action_view_create_subscription)d"
  12. type="action" context="{'default_active_id': active_id}" class="oe_highlight" groups="easy_my_coop.group_energiris_user"/>
  13. </header>
  14. </sheet>
  15. <xpath expr="/form/sheet/group" position='before'>
  16. <group>
  17. <field name="cooperator_register_number" readonly="True" attrs="{'invisible':[('member','=',False)]}"/>
  18. <field name="national_register_number" readonly="True" attrs="{'invisible':[('is_company','=',True)]}" groups="easy_my_coop.group_energiris_super_manager"/>/>
  19. <field name="cooperator" groups="easy_my_coop.group_energiris_super_manager"/>
  20. <field name="member" groups="easy_my_coop.group_energiris_super_manager"/>
  21. <field name="cooperator_type" attrs="{'invisible':[('member','=',False)]}"/>
  22. <field name="effective_date" attrs="{'invisible':[('member','=',False)]}"/>
  23. </group>
  24. <group>
  25. <field name="birthdate" attrs="{'invisible':[('is_company','=',True)]}"/>
  26. <field name="gender" attrs="{'invisible':[('is_company','=',True)]}"/>
  27. </group>
  28. </xpath>
  29. <xpath expr="//page[@name='sales_purchases']" position='after'>
  30. <page string="Shares" name="share" attrs="{'invisible':[('member','=',False)]}" groups="easy_my_coop.group_energiris_user">
  31. <group>
  32. <field name="number_of_share"/>
  33. <field name="total_value"/>
  34. </group>
  35. <field name="share_ids">
  36. <tree>
  37. <field name="effective_date"/>
  38. <field name="share_short_name"/>
  39. <field name="share_number" sum="Total of shares"/>
  40. <field name="share_unit_price"/>
  41. <field name="total_amount_line" sum="Total subscribed amount"/>
  42. </tree>
  43. </field>
  44. </page>
  45. </xpath>
  46. </field>
  47. </record>
  48. <record id="view_partner_tree_easy_my_coop" model="ir.ui.view">
  49. <field name="name">res.partner.tree.easy_my_coop</field>
  50. <field name="model">res.partner</field>
  51. <field name="inherit_id" ref="base.view_partner_tree"/>
  52. <field name="arch" type="xml">
  53. <xpath expr="/tree/field[@name='display_name']" position='after'>
  54. <field name="cooperator_register_number" />
  55. <field name="cooperator_type"/>
  56. <field name="effective_date"/>
  57. </xpath>
  58. </field>
  59. </record>
  60. <record id="view_res_partner_filter_coop" model="ir.ui.view">
  61. <field name="name">res.partner.select</field>
  62. <field name="model">res.partner</field>
  63. <field name="inherit_id" ref="base.view_res_partner_filter"/>
  64. <field name="arch" type="xml">
  65. <xpath expr="//filter[@name='supplier']" position='after'>
  66. <filter string="Cooperators" name="cooperator" domain="[('cooperator','=',1)]" help="Cooperator Partners"/>
  67. </xpath>
  68. <filter name="salesperson" position="before">
  69. <filter name="Cooperator Type" context="{'group_by': 'cooperator_type'}"/>
  70. </filter>
  71. </field>
  72. </record>
  73. <menuitem name="Cooperators" id="menu_easy_my_coop_main_coop" parent="menu_main_easy_my_coop" sequence="5" />
  74. <record id="action_partner_cooperator_form" model="ir.actions.act_window">
  75. <field name="name">Cooperator</field>
  76. <field name="type">ir.actions.act_window</field>
  77. <field name="res_model">res.partner</field>
  78. <field name="view_type">form</field>
  79. <field name="view_mode">kanban,tree,form</field>
  80. <field name="domain">[('cooperator','=',True),('member','=',True),('old_member','=',False)]</field>
  81. <field name="context">{'default_cooperator':1, 'search_default_cooperator':1}</field>
  82. <field name="filter" eval="True"/>
  83. <field name="help" type="html">
  84. <p class="oe_view_nocontent_create">
  85. Click to add a contact in your address book.
  86. </p><p>
  87. OpenERP helps you easily track all activities related to
  88. a cooperator: discussions, history of business opportunities,
  89. documents, etc.
  90. </p>
  91. </field>
  92. </record>
  93. <menuitem id="menu_easy_my_coop_cooperator" name="Cooperators" parent="menu_easy_my_coop_main_coop" action="action_partner_cooperator_form" sequence="100"/>
  94. <record id="action_partner_cooperator_candidate_form" model="ir.actions.act_window">
  95. <field name="name">Cooperator</field>
  96. <field name="type">ir.actions.act_window</field>
  97. <field name="res_model">res.partner</field>
  98. <field name="view_type">form</field>
  99. <field name="view_mode">kanban,tree,form</field>
  100. <field name="domain">[('cooperator','=',True),('member','=',False),('old_member','=',False)]</field>
  101. <field name="context">{'default_cooperator':1, 'search_default_cooperator':1}</field>
  102. <field name="filter" eval="True"/>
  103. <field name="help" type="html">
  104. <p class="oe_view_nocontent_create">
  105. Click to add a contact in your address book.
  106. </p><p>
  107. OpenERP helps you easily track all activities related to
  108. a cooperator: discussions, history of business opportunities,
  109. documents, etc.
  110. </p>
  111. </field>
  112. </record>
  113. <menuitem id="menu_easy_my_coop_cooperator_candidate" name="Cooperator Candidates" parent="menu_easy_my_coop_main_coop" action="action_partner_cooperator_candidate_form" sequence="150"/>
  114. </data>
  115. </openerp>