Skip to content

Commit

Permalink
Merge PR #4667 into 16.0
Browse files Browse the repository at this point in the history
Signed-off-by pedrobaeza
  • Loading branch information
OCA-git-bot committed Jan 22, 2025
2 parents 8c61567 + dffd75a commit 227c325
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions openupgrade_scripts/scripts/base/16.0.1.3/pre-migration.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,18 @@ def login_or_registration_required_at_checkout(cr):


def update_translatable_fields(cr):
# Fix terms with wrong to_translate state. DBs with long version history could have
# terms that didn't have the right state and those would be ignored
openupgrade.logged_query(
cr,
"""
UPDATE ir_translation set state = 'translated'
WHERE type = 'model'
AND state = 'to_translate'
AND value is NOT NULL
AND value IS DISTINCT FROM src
""",
)
# exclude fields from translation update
exclusions = {
# ir.actions.* inherits the name and help columns from ir.actions.actions
Expand Down

0 comments on commit 227c325

Please sign in to comment.