From 376761fafe0a0e1f82861f74d4654223a68cd19a Mon Sep 17 00:00:00 2001 From: mreficent Date: Wed, 7 Jun 2017 10:54:25 +0200 Subject: [PATCH] [10.0][FIX] survey --- .../10.0.2.0/openupgrade_analysis_work.txt | 3 +++ addons/survey/migrations/10.0.2.0/pre-migration.py | 14 ++++++++++++++ odoo/openupgrade/doc/source/modules90-100.rst | 2 +- 3 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 addons/survey/migrations/10.0.2.0/pre-migration.py diff --git a/addons/survey/migrations/10.0.2.0/openupgrade_analysis_work.txt b/addons/survey/migrations/10.0.2.0/openupgrade_analysis_work.txt index 18380c8133bb..fd32e6e07ed0 100644 --- a/addons/survey/migrations/10.0.2.0/openupgrade_analysis_work.txt +++ b/addons/survey/migrations/10.0.2.0/openupgrade_analysis_work.txt @@ -8,8 +8,11 @@ DEL ir.actions.todo: base.open_menu DEL ir.cron: survey.ir_cron_clean_empty_surveys NEW ir.ui.view: survey.survey_survey_view_search NEW ir.values: survey.survey_values_action_clean_test_answers +# NOTHING TO DO NEW res.groups: survey.group_survey_manager NEW res.groups: survey.group_survey_user DEL res.groups: base.group_survey_manager DEL res.groups: base.group_survey_user +# Done: Rename the old groups to the new ones NEW res.users: base.default_user +# NOTHING TO DO diff --git a/addons/survey/migrations/10.0.2.0/pre-migration.py b/addons/survey/migrations/10.0.2.0/pre-migration.py new file mode 100644 index 000000000000..493f08dbe3f5 --- /dev/null +++ b/addons/survey/migrations/10.0.2.0/pre-migration.py @@ -0,0 +1,14 @@ +# -*- coding: utf-8 -*- +# Copyright 2017 Eficent +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). +from openupgradelib import openupgrade + +xmlid_renames = [ + ('base.group_survey_user', 'survey.group_survey_user'), + ('base.group_survey_manager', 'survey.group_survey_manager'), +] + + +@openupgrade.migrate() +def migrate(env, version): + openupgrade.rename_xmlids(env.cr, xmlid_renames) diff --git a/odoo/openupgrade/doc/source/modules90-100.rst b/odoo/openupgrade/doc/source/modules90-100.rst index 1dffe51ac97a..16e0c3ebdd66 100644 --- a/odoo/openupgrade/doc/source/modules90-100.rst +++ b/odoo/openupgrade/doc/source/modules90-100.rst @@ -467,7 +467,7 @@ missing in the new release are marked with |del|. +-----------------------------------+-----------------------------------+ |subscription | Nothing to do | +-----------------------------------+-----------------------------------+ -|survey | Nothing to do | +|survey | Done | +-----------------------------------+-----------------------------------+ |survey_crm | Nothing to do | +-----------------------------------+-----------------------------------+