Skip to content

Commit 2637da3

Browse files
author
Pedro M. Baeza
authored
Merge pull request OCA#5485 from sebalix/15.0-repair-fix-map_values
[15.0][OU-FIX] repair: copy repair_order.state column before updating its data
2 parents 8b4d2ea + 2f96c23 commit 2637da3

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

openupgrade_scripts/scripts/repair/15.0.1.0/post-migration.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ def migrate(env, version):
1414
)
1515
openupgrade.map_values(
1616
env.cr,
17-
"state",
17+
openupgrade.get_legacy_name("state"),
1818
"state",
1919
[("invoice_except", "2binvoiced")],
2020
table="repair_order",

openupgrade_scripts/scripts/repair/15.0.1.0/pre-migration.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,3 +12,7 @@ def migrate(env, version):
1212
openupgrade.convert_field_to_html(
1313
env.cr, "repair_order", "quotation_notes", "quotation_notes"
1414
)
15+
openupgrade.copy_columns(
16+
env.cr,
17+
{"repair_order": [("state", None, None)]},
18+
)

0 commit comments

Comments
 (0)