From ca8d36839615ab963e5f3c7ab3c7675136bacde8 Mon Sep 17 00:00:00 2001
From: Julien Ortet <julien@le-filament.com>
Date: Thu, 10 Apr 2025 15:14:16 +0200
Subject: [PATCH] [fix] fix bug

---
 models/res_partner.py | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/models/res_partner.py b/models/res_partner.py
index 8bb8d8d..4688e15 100644
--- a/models/res_partner.py
+++ b/models/res_partner.py
@@ -120,7 +120,7 @@ class ScopPartner(models.Model):
                     ldt.project_id.cgscop_timesheet_code_id.domain == 'D'):
                     rec.realized_time = rec.realized_time + ldt.unit_amount
                 # On totalise les heures facturés
-                if ldt.project_id.hasattr("creation_invoiced") and ldt.project_id.creation_invoiced == True:
+                if ldt.project_id.creation_invoiced == True:
                     if (ldt.project_id.cgscop_timesheet_code_id != False and
                         ldt.project_id.cgscop_timesheet_code_id.domain == 'A'):
                         rec.realized_followup = rec.realized_followup + ldt.unit_amount
-- 
GitLab