Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.
Module: Automation Rules
Entity: base.automation
Compute Method: _compute_trg_field_ref
| Inputs | Method | Outputs |
|---|---|---|
|
- to_reset = self.filtered(lambda a: a.trigger not in ['on_stage_set', 'on_tag_set'] or len(a.trigger_field_ids) != 1) - to_reset.trg_field_ref = False - for automation in (self - to_reset): - relation = automation.trigger_field_ids.relation - automation.trg_field_ref_model_name = relation - # always re-assign to an empty value to make sure we have no discrepencies - automation.trg_field_ref = self.env[relation] + self.trg_field_ref = False |
|
