Partner Custom Attributes
partner_custom_attributes · OCA/product-attribute
-
Security25/25No findings
-
Activity0/25Last human commit 122 months ago
-
Required by5/250 modules depend on it
-
Maturity25/25In 4 Odoo series since 7.0
Heuristic over the facts below, not an audit · How it's computed
Migration considerations
ResPartner— Class 'ResPartner' still inherits from the old-style `osv.Model` API: rewrite it against `models.Model`/`models.TransientModel`/`models.AbstractModel` - the old `osv`/`orm` API was removed entirely in modern Odoo. migration-old-api-base · sourceResPartner— Class 'ResPartner' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourceResPartner— Migrating to 16.0: the web client no longer calls `fields_view_get`: override `_get_view` instead. migration-fields-view-get · sourceopen_partner_by_attribute_set— Class 'open_partner_by_attribute_set' declares `_columns` as a plain dict: old-style field/default declarations, replace with `fields.X(...)` class attributes and `default=`. migration-old-style-fields · sourceres_partner_form_view_set_button— Migrating to 17.0: `attrs=`/`states=` are rejected in views: convert them to Python expressions in `invisible`/`readonly`/`required`, keeping the original AND/OR logic. migration-view-attrs-states · source- Since 10.0: the `openerp` namespace was renamed to `odoo`; only a deprecated `openerp.addons` alias remained. (`openerp.osv`) (2 occurrences in this file) migration-openerp-import · source
- Since 10.0: the `openerp` namespace was renamed to `odoo`; only a deprecated `openerp.addons` alias remained. (`openerp.osv.orm`) migration-openerp-import · source
Migration review checklist, not a compatibility verdict. "Migrating to X.0" applies once you upgrade to that version; "Since X.0" means this version already ignores or rejects that code. Methodology
Description
Partner custom attributes
This module adds the possibility to easily create custom fields on Partners. Each partner can be linked to an attribute set. Each attribute has custom fields.
This module is inspired by the module product_custom_attributes by Benoît GUILLOT, Akretion
Dependencies
- Odoo dependencies
- None
- Python dependencies
- None
- System dependencies
- None
- Required by
- None
Code analysis
Extracted from the source by best-effort static analysis (no code is executed); details may be incomplete.
Views touched 3
| XML ID | Name | Model | Type | Status |
|---|---|---|---|---|
open_partner_by_attribute_set_view |
open.partner.by.attribute.set.view | open.partner.by.attribute.set | form | New |
partner_attributes_form_view |
partner.attributes.normal.wizard | res.partner | form | New |
res_partner_form_view_set_button |
attributes.partner.normal.form | res.partner | form | Inherits base.view_partner_form |
HTTP endpoints 0
No HTTP endpoints found for this module.
Models touched 2
No new fields.
Public methods (1)-
open_partner_by_attribute(self, cr, uid, ids, context=None)Opens a partner by attributes Returns a custom action built modifying the original one.
No new fields.
Public methods (3)-
fields_view_get(self, cr, uid, view_id=None, view_type='form', context=None, toolbar=False, submenu=False)Dynamically add attributes to the view. Return field_view_get. Modifies dynamically the view to show the attributes. If the users presses the Open Attributes button, the attributes are shown in a new form field. Otherwise, if the attribute set is known beforehand, attributes are added to a new tab in the main form view. -
open_attributes(self, cr, uid, ids, context=None)Open the attributes of an object. Return action. This method is called when the user presses the Open Attributes button in the form view of the object. It opens a dynamically-built form view. :param ids: this is normally a singleton. If a longer list is passed, we consider only the first item. -
save_and_close_partner_attributes(self, cr, uid, ids, context=None)Button to save and close. Return action.
Loading…
Loading…
Loading…