[FIX] account: define method in correct model
Oversight of previous forward-port.
This commit is contained in:
@@ -205,6 +205,12 @@ class account_abstract_payment(models.AbstractModel):
|
|||||||
total += payment_currency.with_context(date=self.payment_date).compute(amount_total, currency)
|
total += payment_currency.with_context(date=self.payment_date).compute(amount_total, currency)
|
||||||
return total
|
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')
|
@api.onchange('journal_id')
|
||||||
def _onchange_journal(self):
|
def _onchange_journal(self):
|
||||||
res = super(account_register_payments, self)._onchange_journal()
|
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))
|
self.amount = abs(self._compute_payment_amount(invoices))
|
||||||
return res
|
return res
|
||||||
|
|
||||||
|
|
||||||
class account_register_payments(models.TransientModel):
|
|
||||||
_name = "account.register.payments"
|
|
||||||
_inherit = 'account.abstract.payment'
|
|
||||||
_description = "Register payments on multiple invoices"
|
|
||||||
|
|
||||||
@api.model
|
@api.model
|
||||||
def default_get(self, fields):
|
def default_get(self, fields):
|
||||||
rec = super(account_register_payments, self).default_get(fields)
|
rec = super(account_register_payments, self).default_get(fields)
|
||||||
|
|||||||
Reference in New Issue
Block a user