diff --git a/services/operation_services.py b/services/operation_services.py index 07ed716400c773b80b26fbf82df501fc39cc1f1c..5dd7a46130b2e66901dff1381d49c444c7b3c988 100644 --- a/services/operation_services.py +++ b/services/operation_services.py @@ -196,7 +196,7 @@ class OperationsService(Component): if type == "invoice": # Récupération de toutes les factures liées à l'opération spécifiée acc_account_ids = self.env["acc.account"].sudo().search( - [("acc_operation_id", "=", _id)] + [("acc_operation_id", "=", _id), ("state", "=", "published")] ) datas["documents"] = acc_account_ids.mapped(lambda n: {