Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docsource/modules180-190.rst
Original file line number Diff line number Diff line change
Expand Up @@ -576,7 +576,7 @@ Module coverage 18.0 -> 19.0
+---------------------------------------------------+----------------------+-------------------------------------------------+
| l10n_nl | | |
+---------------------------------------------------+----------------------+-------------------------------------------------+
| l10n_no | | |
| l10n_no |Done | |
+---------------------------------------------------+----------------------+-------------------------------------------------+
| l10n_nz | | |
+---------------------------------------------------+----------------------+-------------------------------------------------+
Expand Down
24 changes: 24 additions & 0 deletions openupgrade_scripts/scripts/l10n_no/19.0.2.1/pre-migration.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
from openupgradelib import openupgrade

# Without this column-add the 19.0 account chart_template loader's
# `account.tax.mapped(...)` query references account_tax.l10n_no_standard_code
# before the l10n_no install step would have created the column, crashing
# the migration with UndefinedColumn. See upgrade_analysis.txt — the field
# is NEW in 19.0 and there is no upstream pre-migration script in stock
# OpenUpgrade as of 19.0.2.1.
_added_fields = [
(
"l10n_no_standard_code",
"account.tax",
"account_tax",
"char",
None,
"l10n_no",
None,
),
]


@openupgrade.migrate()
def migrate(env, version):
openupgrade.add_fields(env, _added_fields)
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
---Models in module 'l10n_no'---
---Fields in module 'l10n_no'---
l10n_no / account.journal / invoice_reference_model (False): selection_keys added: [number] (most likely nothing to do)

# NOTHING TO DO: pure selection-keys widening on an existing column; Odoo's update_db handles it.

l10n_no / account.tax / l10n_no_standard_code (char) : NEW

# DONE: added in pre-migration as a NULL column so the 19.0 account chart_template loader (account.tax.mapped) doesn't crash with UndefinedColumn before the l10n_no install step runs.

---XML records in module 'l10n_no'---
NEW ir.ui.view: l10n_no.account_tax_form_inherit_l10n_no

# NOTHING TO DO: standard view record loaded during install.
Loading