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.

58 lines
2.2 KiB

  1. <?xml version="1.0" encoding="utf-8"?>
  2. <!--
  3. Copyright 2014-2018 Akretion France
  4. @author: Alexis de Lattre <alexis.delattre@akretion.com>
  5. License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl).
  6. -->
  7. <odoo>
  8. <record id="crm_case_form_view_leads" model="ir.ui.view">
  9. <field name="name">crm_phone.crm_lead.form</field>
  10. <field name="model">crm.lead</field>
  11. <field name="inherit_id" ref="crm.crm_case_form_view_leads"/>
  12. <field name="arch" type="xml">
  13. <div name="button_box" position="inside">
  14. <button class="oe_inline oe_stat_button" type="action"
  15. name="%(crm_phone.crm_phonecall_action)d"
  16. icon="fa-phone"
  17. context="{'search_default_opportunity_id': active_id}">
  18. <field string="Calls" name="phonecall_count" widget="statinfo"/>
  19. </button>
  20. </div>
  21. <field name="mobile" position="attributes">
  22. <attribute name="widget">phone</attribute>
  23. </field>
  24. </field>
  25. </record>
  26. <record id="crm_case_form_view_oppor" model="ir.ui.view">
  27. <field name="name">crm_phone.case.view_opportuniy.form</field>
  28. <field name="model">crm.lead</field>
  29. <field name="inherit_id" ref="crm.crm_case_form_view_oppor"/>
  30. <field name="arch" type="xml">
  31. <div name="button_box" position="inside">
  32. <button class="oe_inline oe_stat_button" type="action"
  33. name="%(crm_phone.crm_phonecall_action)d"
  34. icon="fa-phone"
  35. context="{'search_default_opportunity_id': active_id}">
  36. <field string="Calls" name="phonecall_count" widget="statinfo"/>
  37. </button>
  38. </div>
  39. <field name="mobile" position="replace"/>
  40. <field name="phone" position="after">
  41. <field name="partner_address_mobile"
  42. attrs="{'invisible': [('partner_address_mobile', '==', False)]}"
  43. readonly="1"
  44. widget="phone"
  45. string="Mobile"/>
  46. <field name="mobile"
  47. attrs="{'invisible': [('partner_address_mobile', '!=', False)]}"
  48. widget="phone"/>
  49. </field>
  50. </field>
  51. </record>
  52. </odoo>