`_address_fields` are used by `update_address` [1], which is in turn
called by `_fields_sync` and `_children_sync`.
This mechanism is in charge of synchronizing parent/children address fields
for contacts of type == "contact", as they don't really have an address of
their own. They simply copy the address of their parent.
Without this fix, not only the zip_id is not sync'ed, but also in some cases
an exception may be raised by `_check_zip_id`, due to only some fields being
sync'ed but not all, creating inconsistencies between zip_id and other address
fields.
[1]: https://github.com/odoo/odoo/blob/20648ef21/odoo/addons/base/models/res_partner.py#L429
Having this rule activated by default in tests environments makes other tests to fail due to the additional constraint not expected by them, so what we are doing is:
- Having the rule deactivated by default.
- On a post-init hook, we activate it only if we are not in a test environment.
- On own modules tests, we activate it as well
TT30292
===========================================
Exclude some records from the deduplication
===========================================
This module extends the possibilities of the contact deduplication allowing
to filter the applicable set according several criteria.
For now, only the filter for restricting the deduplication to only companies or
only contacts is implemented.
Usage
=====
To use this module, you need to:
"Parent company set (Contacts)" in the section 'Exclude contacts having'.
kind of records.
OCA Transbot updated translations from Transifex
In Odoo v14, ir.actions.act_window have only access rights for admin while a user had read access in previous versions. Odoo provides now a function (_for_xml_id) that returns the action read with sudo.