[FIX] account: define method in correct model

Oversight of previous forward-port.
This commit is contained in:
Christophe Simonis
2018-08-06 17:25:15 +02:00
parent 427f717d18
commit ff80efd71e
+6 -6
View File
@@ -205,6 +205,12 @@ class account_abstract_payment(models.AbstractModel):
total += payment_currency.with_context(date=self.payment_date).compute(amount_total, currency)
return total
class account_register_payments(models.TransientModel):
_name = "account.register.payments"
_inherit = 'account.abstract.payment'
_description = "Register payments on multiple invoices"
@api.onchange('journal_id')
def _onchange_journal(self):
res = super(account_register_payments, self)._onchange_journal()
@@ -213,12 +219,6 @@ class account_abstract_payment(models.AbstractModel):
self.amount = abs(self._compute_payment_amount(invoices))
return res
class account_register_payments(models.TransientModel):
_name = "account.register.payments"
_inherit = 'account.abstract.payment'
_description = "Register payments on multiple invoices"
@api.model
def default_get(self, fields):
rec = super(account_register_payments, self).default_get(fields)