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.

18 lines
450 B

  1. # Copyright 2018 Tecnativa - Sergio Teruel
  2. # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl).
  3. from odoo import api, fields, models
  4. class ResPartner(models.Model):
  5. _inherit = 'res.partner'
  6. group_id = fields.Many2one(
  7. comodel_name='res.partner',
  8. string='Group',
  9. )
  10. @api.model
  11. def _commercial_fields(self):
  12. res = super()._commercial_fields()
  13. res.append('group_id')
  14. return res