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

Module: Github Connector

Entity: github.team

Compute Method: _compute_partner_qty

Inputs Method Outputs
  • id
data = self.env["github.team.partner"].read_group(
            [("team_id", "in", self.ids)], ["team_id"], ["team_id"]
        )
mapping = {data["team_id"][0]: data["team_id_count"] for data in data}
for item in self:
            item.partner_qty = mapping.get(item.id, 0)

Back to entity