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

Module: Discuss

Entity: mail.guest

Compute Method: _compute_im_status

Inputs Method Outputs
presences = self.env["bus.presence"].sudo().search([("guest_id", "in", self.ids)])
im_status_by_guest = {presence.guest_id: presence.status for presence in presences}
for guest in self:
            guest.im_status = im_status_by_guest.get(guest, "offline")

Back to entity