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.

29 lines
1.2 KiB

  1. <?xml version="1.0" encoding="utf-8" ?>
  2. <!-- Copyright 2015 Grupo ESOC Ingeniería de Servicios, S.L.U. - Jairo Llopis
  3. Copyright 2017 Tecnativa - Pedro M. Baeza
  4. License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl). -->
  5. <odoo>
  6. <record id="users_form" model="ir.ui.view">
  7. <field name="name">Add second last name</field>
  8. <field name="model">res.users</field>
  9. <field name="inherit_id" ref="partner_firstname.view_users_form" />
  10. <field name="arch" type="xml">
  11. <field name="firstname" position="attributes">
  12. <attribute name="attrs">
  13. {'required': [('lastname', '=', False), ('lastname2', '=', False)]}
  14. </attribute>
  15. </field>
  16. <field name="lastname" position="attributes">
  17. <attribute name="attrs">
  18. {'required': [('firstname', '=', False), ('lastname2', '=', False)]}
  19. </attribute>
  20. </field>
  21. <field name="lastname" position="after">
  22. <field
  23. name="lastname2"
  24. attrs="{'required': [('firstname', '=', False), ('lastname', '=', False)]}"
  25. />
  26. </field>
  27. </field>
  28. </record>
  29. </odoo>