From d71f2116d942a9b2ecb0a7fb15359ebd308f8ff9 Mon Sep 17 00:00:00 2001 From: Nathan de Pryck Date: Tue, 28 May 2019 08:23:27 +0000 Subject: [PATCH] [FIX] account_voucher: unnecessary copy of payment memo Before this commit, the payment memo was copied during the duplication of a voucher. The issue is that the payment memo is not always shown in the view, and it's mostly unique by voucher. Now, the payment memo it's not copied anymore. opw-1986544 closes odoo/odoo#33708 Signed-off-by: Nicolas Martinelli (nim) --- addons/account_voucher/models/account_voucher.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/account_voucher/models/account_voucher.py b/addons/account_voucher/models/account_voucher.py index 14161aa4251..73ed5f3e9bd 100644 --- a/addons/account_voucher/models/account_voucher.py +++ b/addons/account_voucher/models/account_voucher.py @@ -37,7 +37,7 @@ class AccountVoucher(models.Model): ('purchase', 'Purchase') ], string='Type', readonly=True, states={'draft': [('readonly', False)]}, oldname="type") name = fields.Char('Payment Memo', - readonly=True, states={'draft': [('readonly', False)]}, default='') + readonly=True, states={'draft': [('readonly', False)]}, default='',copy=False) date = fields.Date("Bill Date", readonly=True, index=True, states={'draft': [('readonly', False)]}, copy=False, default=fields.Date.context_today)