From e8af63347ae2a42a3c089a9f218ac955d16ce8fb Mon Sep 17 00:00:00 2001 From: Holger Brunn Date: Mon, 23 Jun 2025 10:53:54 +0200 Subject: [PATCH] [OU-ADD] mrp_account --- docsource/modules170-180.rst | 2 +- .../mrp_account/18.0.1.0/post-migration.py | 11 ++++ .../18.0.1.0/upgrade_analysis_work.txt | 53 +++++++++++++++++++ 3 files changed, 65 insertions(+), 1 deletion(-) create mode 100644 openupgrade_scripts/scripts/mrp_account/18.0.1.0/post-migration.py create mode 100644 openupgrade_scripts/scripts/mrp_account/18.0.1.0/upgrade_analysis_work.txt diff --git a/docsource/modules170-180.rst b/docsource/modules170-180.rst index e0236a0e9cfe..fecbbbf7782d 100644 --- a/docsource/modules170-180.rst +++ b/docsource/modules170-180.rst @@ -710,7 +710,7 @@ Module coverage 17.0 -> 18.0 +---------------------------------------------------+----------------------+-------------------------------------------------+ | mrp |Done | | +---------------------------------------------------+----------------------+-------------------------------------------------+ -| mrp_account | | | +| mrp_account |Done | | +---------------------------------------------------+----------------------+-------------------------------------------------+ | mrp_landed_costs | |No DB layout changes. | +---------------------------------------------------+----------------------+-------------------------------------------------+ diff --git a/openupgrade_scripts/scripts/mrp_account/18.0.1.0/post-migration.py b/openupgrade_scripts/scripts/mrp_account/18.0.1.0/post-migration.py new file mode 100644 index 000000000000..27cbe05fd876 --- /dev/null +++ b/openupgrade_scripts/scripts/mrp_account/18.0.1.0/post-migration.py @@ -0,0 +1,11 @@ +# Copyright 2025 Hunki Enterprises BV +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from openupgradelib import openupgrade, openupgrade_180 + + +@openupgrade.migrate() +def migrate(env, version): + openupgrade_180.convert_company_dependent( + env, "product.category", "property_stock_account_production_cost_id" + ) diff --git a/openupgrade_scripts/scripts/mrp_account/18.0.1.0/upgrade_analysis_work.txt b/openupgrade_scripts/scripts/mrp_account/18.0.1.0/upgrade_analysis_work.txt new file mode 100644 index 000000000000..f5f40609b41e --- /dev/null +++ b/openupgrade_scripts/scripts/mrp_account/18.0.1.0/upgrade_analysis_work.txt @@ -0,0 +1,53 @@ +---Models in module 'mrp_account'--- +new model mrp.account.wip.accounting [transient] +new model mrp.account.wip.accounting.line [transient] + +# NOTHING TO DO + +---Fields in module 'mrp_account'--- +mrp_account / account.analytic.applicability / business_domain (False) : selection_keys is now '['bill', 'expense', 'general', 'invoice', 'manufacturing_order', 'purchase_order', 'timesheet']' ('['bill', 'expense', 'general', 'invoice', 'manufacturing_order', 'purchase_order']') + +# NOTHING TO DO: key added not connected to this module + +mrp_account / account.move / wip_production_ids (many2many): NEW relation: mrp.production + +# NOTHING TO DO: new functionality + +mrp_account / mrp.bom / analytic_distribution_search (json): DEL stored: False +mrp_account / mrp.bom / analytic_distribution_text (text): DEL stored: False +mrp_account / mrp.bom / analytic_precision (integer) : DEL stored: False + +# NOTHING TO DO: removed functionality + +mrp_account / mrp.production / analytic_account_ids (many2many): DEL relation: account.analytic.account + +# NOTHING TO DO: informational field derived from analytic distribution + +mrp_account / mrp.production / analytic_distribution (json) : DEL +mrp_account / mrp.production / analytic_distribution_search (json): DEL stored: False +mrp_account / mrp.production / analytic_precision (integer) : DEL stored: False +mrp_account / mrp.workcenter / analytic_distribution_search (json): DEL stored: False + +# NOTHING TO DO: changes of the analytic mixin + +mrp_account / mrp.workcenter / expense_account_id (many2one) : NEW relation: account.account +mrp_account / mrp.workcenter.productivity / account_move_line_id (many2one): NEW relation: account.move.line + +# NOTHING TO DO: new functionality + +mrp_account / product.category / property_stock_account_production_cost_id (many2one): needs conversion to v18-style company dependent + +# DONE in post-migration + +---XML records in module 'mrp_account'--- +NEW ir.actions.act_window: mrp_account.action_wip_accounting +NEW ir.model.access: mrp_account.access_mrp_wip_accounting +NEW ir.model.access: mrp_account.access_mrp_wip_accounting_line +NEW ir.model.constraint: mrp_account.constraint_mrp_account_wip_accounting_line_check_debit_credit +NEW ir.ui.view: mrp_account.mrp_workcenter_view_inherit +NEW ir.ui.view: mrp_account.view_move_form_inherit_mrp_account +NEW ir.ui.view: mrp_account.view_wip_accounting_form +DEL ir.ui.view: mrp_account.mrp_bom_form_view_inherited +DEL ir.ui.view: mrp_account.view_production_tree_view_inherit + +# NOTHING TO DO