Skip to content
Merged
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
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
---Fields in module 'base_action_rule'---
base_action_rule / base.action.rule / kind (selection) : now required
# TODO: pre-migration: if blank default to 'on_create' (or any other)
# Done: Disable and set to "on_time" rules with this field not filled.
This is very uncommon, as in view, the field was already required.
---XML records in module 'base_action_rule'---
NEW ir.ui.view: base_action_rule.view_base_action_rule_search
# NOTHING TO DO
20 changes: 20 additions & 0 deletions addons/base_action_rule/migrations/10.0.1.0/pre-migration.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# -*- coding: utf-8 -*-
# Copyright 2017 Tecnativa - Pedro M. Baeza
# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html).

from openupgradelib import openupgrade


@openupgrade.migrate()
def migrate(env, version):
env.cr.execute(
"""
UPDATE
base_action_rule
SET
active = False,
kind = 'on_time'
WHERE
kind IS NULL
"""
)
2 changes: 1 addition & 1 deletion odoo/openupgrade/doc/source/modules90-100.rst
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ Status :
+-----------------------------------+-----------------------------------+
|base | Done |
+-----------------------------------+-----------------------------------+
|base_action_rule | |
|base_action_rule | Done |
+-----------------------------------+-----------------------------------+
|base_gengo | |
+-----------------------------------+-----------------------------------+
Expand Down