From be08725acbef089bdf890ff217d91740db69e69f Mon Sep 17 00:00:00 2001 From: Sergi Almacellas Abellana Date: Thu, 16 Jun 2022 14:29:15 +0200 Subject: [PATCH] Clear invoiced progress when copying works issue11545 review423331004 (grafted from cf92953d5ad93874e7d7e1e3d0a577cddfffe275) --HG-- branch : 6.0 --- project.py | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/project.py b/project.py index d3efe1aa8b..e909b02d41 100644 --- a/project.py +++ b/project.py @@ -205,6 +205,15 @@ class Progress: origins.append(invoiced_progress) return origins + @classmethod + def copy(cls, records, default=None): + if default is None: + default = {} + else: + default = default.copy() + default.setdefault('invoiced_progress', None) + return super().copy(records, default=default) + class Timesheet: