Repository
OCA/partner-contact · module folder · Try on Runboat
Module version
0.1.0
Category
Customer Relationship Management
Folder size
0.04 MB
License
AGPL-3
Application
No
Auto-installable
No
Website
https://github.com/oca/partner-contact
Last tracking update
2026-08-07 07:17:48
Authors
Odoo Community Association (OCA), Therp BV
Maintainers
Odoo Community Association (OCA), Therp BV
Committers
Ronald Portier, OCA Transbot, OCA-git-bot, oca-travis
Odoo dependencies
OCA/partner-contact:
odoo/odoo:
- web
- bus
Python dependencies
None
System dependencies
None
Required by
None
Description

Code Analysis

Views touched (2)
XML IDNameModelTypeStatus
form_res_partner_relation_type res.partner.relation.type form Inherits partner_multi_relation.form_res_partner_relation_type
view_partner_form view.partner.form res.partner form Inherits base.view_partner_form
HTTP endpoints (0)

No HTTP endpoints found for this module.

Models touched (4)

New fields (3)
  • has_partner_above Boolean
    compute='_compute_partners_above' readonly=True
  • partner_above_hierarchy Char
    compute='_compute_partners_above' readonly=True string='Upper level partners'
  • partner_above_ids One2many → res.partner.relation.hierarchy
    comodel_name='res.partner.relation.hierarchy' inverse_name='partner_id' readonly=True string='Partners above in hierarchy'
Public methods (1)
  • is_above(self, other_partner)
    @api.multi
    Check whether this partner is above other_partner.

New fields (0)

No new fields.

Public methods (1)
  • create(self, vals)
    @api.model
    Prevent contradictory links in hierarchy. We should not do this in a constraint, as those are only checked after creation has already been done, and other modules might fail when they process in invalid hierarchy when triggered on create. TODO: Prevent this also on write.

New fields (5)
  • hierarchy_display Char
    help='Compact representation of hierarchy' readonly=True required=True string='Hierarchy'
  • level Integer
    help='Number of levels that partner above is higher up' readonly=True required=True string='Level'
  • partner_above_id Many2one → res.partner
    comodel_name='res.partner' help='Partner somewhere above in the hierarchy' readonly=True required=True string='Partner above'
  • partner_below_id Many2one → res.partner
    comodel_name='res.partner' help='Partner immediately below partner above in the hierarchy' readonly=True required=True string='Partner below'
  • partner_id Many2one → res.partner
    comodel_name='res.partner' help='The partner at the base of the hierarchy' readonly=True required=True string='Partner'
Public methods (0)

No public methods.

New fields (1)
  • hierarchy Selection
    default='equal' help="Select wether the relation between the partners can be considered hierarchical. And if so which side is considered 'above'." selection=HIERARCHY_SELECTION string='Partners equal, right above, or left above'
Public methods (0)

No public methods.