diff --git a/addons/sale_timesheet_purchase/models/project_overview.py b/addons/sale_timesheet_purchase/models/project_overview.py index 07bc171f4d6..86484038b37 100644 --- a/addons/sale_timesheet_purchase/models/project_overview.py +++ b/addons/sale_timesheet_purchase/models/project_overview.py @@ -22,7 +22,9 @@ class Project(models.Model): context={'create': False, 'edit': False, 'delete': False} ) }) - account_invoice_lines = self.env['account.move.line'].search([('analytic_account_id', 'in', accounts), ('move_id.type', 'in', ['in_invoice', 'in_refund'])]) + account_invoice_lines = self.env['account.move.line'].search( + [('analytic_account_id', 'in', accounts), + ('move_id.move_type', 'in', ['in_invoice', 'in_refund'])]) account_invoices = account_invoice_lines.mapped('move_id') if account_invoices: stat_buttons.append({