mirror of
https://github.com/OCA/bank-payment.git
synced 2025-02-02 10:37:31 +02:00
sepa attachments migration fix
Sometimes sepa file could have been detached from the corresponding payment order.
This commit is contained in:
committed by
Carlos Roca
parent
989d329e5a
commit
4521c51b98
@@ -39,6 +39,8 @@ def migrate(cr, version):
|
||||
''')
|
||||
|
||||
for sepa_file in cr.dictfetchall():
|
||||
if not sepa_file['payment_order_id']:
|
||||
continue
|
||||
filename = 'sct_%s.xml' % sepa_file['reference'].replace('/', '-')
|
||||
pool['ir.attachment'].create(
|
||||
cr, SUPERUSER_ID, {
|
||||
|
||||
Reference in New Issue
Block a user