diff --git a/invoice.py b/invoice.py index 0e498e8eb8..0e022623a7 100644 --- a/invoice.py +++ b/invoice.py @@ -38,4 +38,14 @@ class Invoice(ModelWorkflow, ModelSQL, ModelView): }, context=context) return res + def copy(self, cursor, user, ids, default=None, context=None): + if default is None: + default = {} + + default = default.copy() + default['open_date'] = False + + return super(Invoice, self).copy(cursor, user, ids, default=default, + context=context) + Invoice()