mirror of
https://github.com/OCA/account-financial-tools.git
synced 2025-02-02 12:47:26 +02:00
[FIX] copy of account invoice did not reset related policy
This commit is contained in:
@@ -44,13 +44,14 @@ class AccountInvoice(orm.Model):
|
||||
}
|
||||
|
||||
def copy_data(self, cr, uid, id, default=None, context=None):
|
||||
"""Ensure that credit lines are not duplicated when copy"""
|
||||
"""Ensure that credit lines and policcy are not copied"""
|
||||
if default is None:
|
||||
default = {}
|
||||
else:
|
||||
default = default.copy()
|
||||
default = default.copy()
|
||||
default['credit_control_line_ids'] = False
|
||||
default['credit_policy_id'] = False
|
||||
return super(AccountInvoice, self).copy_data(
|
||||
cr, uid, id, default=default, context=context)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user