mirror of
https://gitlab.com/flectra-community/l10n-switzerland-flectra.git
synced 2024-12-22 20:31:45 +00:00
Merge branch '2.0-fixed' into '2.0'
[FIX] l10n_ch_pain_base: check partner_bank_id on move_id to prevent expected singleton error See merge request flectra-community/l10n-switzerland-flectra!16
This commit is contained in:
commit
e862366bbd
@ -10,7 +10,7 @@ class AccountMoveLine(models.Model):
|
||||
def _prepare_payment_line_vals(self, payment_order):
|
||||
vals = super(AccountMoveLine, self)._prepare_payment_line_vals(
|
||||
payment_order)
|
||||
if self.move_id and self.move_id.partner_bank_id._is_qr_iban():
|
||||
if self.move_id and self.move_id.partner_bank_id and self.move_id.partner_bank_id._is_qr_iban():
|
||||
if self.move_id.reference_type == 'isr':
|
||||
vals['local_instrument'] = 'CH01'
|
||||
if vals['communication']:
|
||||
|
Loading…
Reference in New Issue
Block a user