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

Module: Peppol

Entity: res.company

Compute Method: _compute_peppol_purchase_journal_id

Inputs Method Outputs
for company in self:
            if not company.peppol_purchase_journal_id and company.peppol_can_send:
                company.peppol_purchase_journal_id = self.env['account.journal'].search([
                    *self.env['account.journal']._check_company_domain(company),
                    ('type', '=', 'purchase'),
                ], limit=1)
                company.peppol_purchase_journal_id.is_peppol_journal = True

Back to entity