mirror of
https://github.com/OCA/bank-payment.git
synced 2025-02-02 10:37:31 +02:00
[FIX] account_payment_order: column "payment_order_type" does not exist during migration to 9.0 (#471)
This commit is contained in:
committed by
Pedro M. Baeza
parent
2e9b0620ed
commit
22c9fbc14a
@@ -24,7 +24,10 @@ def map_payment_type(cr):
|
||||
@openupgrade.migrate(use_env=True)
|
||||
def migrate(env, version):
|
||||
cr = env.cr
|
||||
map_payment_type(cr)
|
||||
table = 'account_payment_order'
|
||||
if (openupgrade.table_exists(cr, table) and
|
||||
openupgrade.column_exists(cr, table, 'payment_order_type')):
|
||||
map_payment_type(cr)
|
||||
|
||||
cr.execute("""
|
||||
UPDATE account_payment_order apo
|
||||
|
||||
Reference in New Issue
Block a user