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

Module: MRP Multi Level

Entity: stock.location

Compute Method: _compute_mrp_area_count

Inputs Method Outputs
  • id
for rec in self:
            areas = self.env["mrp.area"].search([("location_id", "=", rec.id)])
            rec.mrp_area_count = len(areas)

Back to entity