Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.

Module: Maintenance Plan

Entity: maintenance.equipment

Compute Method: _compute_search_maintenance_plan_count

Inputs Method Outputs
  • id
for equipment in self:
            equipment.search_maintenance_plan_count = (
                self.env["maintenance.plan"]
                .with_context(active_test=False)
                .search_count([("search_equipment_id", "=", equipment.id)])
            )

Back to entity