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

Module: Sales

Entity: sale.order

Compute Method: _compute_is_expired

Inputs Method Outputs
today = fields.Date.context_today(self)
for order in self:
            order.is_expired = (
                order.state in ("draft", "sent")
                and order.validity_date
                and order.validity_date < today
            )

Back to entity