[FIX] account: Allow to duplicate supplier invoices
As there's a check for unique supplier reference numbers, you can't duplicate them as the field is copied on the duplicated record. This patch removes the copy for emptying the error. @Tecnativa
This commit is contained in:
@@ -213,7 +213,7 @@ class AccountInvoice(models.Model):
|
||||
move_name = fields.Char(string='Journal Entry Name', readonly=False,
|
||||
default=False, copy=False,
|
||||
help="Technical field holding the number given to the invoice, automatically set when the invoice is validated then stored to set the same number again if the invoice is cancelled, set to draft and re-validated.")
|
||||
reference = fields.Char(string='Vendor Reference',
|
||||
reference = fields.Char(string='Vendor Reference', copy=False,
|
||||
help="The partner reference of this invoice.", readonly=True, states={'draft': [('readonly', False)]})
|
||||
reference_type = fields.Selection('_get_reference_type', string='Payment Reference',
|
||||
required=True, readonly=True, states={'draft': [('readonly', False)]},
|
||||
|
||||
Reference in New Issue
Block a user