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.

54 lines
2.6 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!-- Copyright 2015 Pedro M. Baeza <pedro.baeza@tecnativa.com>
  3. Copyright 2015-16 Antonio Espinosa <antonio.espinosa@tecnativa.com>
  4. Copyright 2015 Javier Iniesta <javieria@antiun.com>
  5. Copyright 2016 Antonio Espinosa - <antonio.espinosa@tecnativa.com>
  6. License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). -->
  7. <odoo>
  8. <record model="ir.ui.view" id="view_partner_form">
  9. <field name="name">Partner Form with mailing contacts</field>
  10. <field name="model">res.partner</field>
  11. <field name="inherit_id" ref="base.view_partner_form"/>
  12. <field name="groups_id" eval="[(4, ref('mass_mailing.group_mass_mailing_user'))]"/>
  13. <field name="arch" type="xml">
  14. <div name="button_box" position="inside">
  15. <button name="%(mass_mailing.action_view_mass_mailing_contacts)d"
  16. context="{'search_default_partner_id': active_id,
  17. 'default_partner_id': active_id}"
  18. type="action"
  19. class="oe_stat_button oe_inline"
  20. icon="fa-envelope-o">
  21. <field name="mass_mailing_contacts_count"
  22. widget="statinfo"
  23. string="Mailing contacts"/>
  24. </button>
  25. <button name="%(mass_mailing.action_view_mail_mail_statistics)d"
  26. context="{'search_default_partner_id': active_id,
  27. 'default_partner_id': active_id}"
  28. type="action"
  29. class="oe_stat_button oe_inline"
  30. icon="fa-envelope-o">
  31. <field name="mass_mailing_stats_count"
  32. widget="statinfo"
  33. string="Mass mailing stats"/>
  34. </button>
  35. </div>
  36. </field>
  37. </record>
  38. <record id="view_res_partner_filter" model="ir.ui.view">
  39. <field name="name">Partner Search with mailing contacts</field>
  40. <field name="model">res.partner</field>
  41. <field name="inherit_id" ref="base.view_res_partner_filter"/>
  42. <field name="groups_id" eval="[(4, ref('mass_mailing.group_mass_mailing_user'))]"/>
  43. <field name="priority">20</field>
  44. <field name="arch" type="xml">
  45. <field name="category_id" position="after">
  46. <field name="mass_mailing_contact_ids" string="Mailing List"
  47. filter_domain="[('mass_mailing_contact_ids.list_ids','ilike', self)]"/>
  48. </field>
  49. </field>
  50. </record>
  51. </odoo>