Odoo Mindscape. Understand Odoo faster. Explore modules, fields, dependencies and version differences in one place instead of digging through the source code.
Module: PMS - Accounting
Entity: pms.property
Compute Method: _compute_invoice_count
| Inputs | Method | Outputs |
|---|---|---|
|
+ for rec in self: + invoices = rec.invoice_line_ids.mapped("move_id").filtered( + lambda r: r.move_type in ("out_invoice", "out_refund") + ) + bills = rec.invoice_line_ids.mapped("move_id").filtered( + lambda r: r.move_type in ("in_invoice", "in_refund") + ) + rec.invoice_ids = invoices + rec.invoice_count = len(invoices) + rec.bill_ids = bills + rec.bill_count = len(bills) |
|
