From 35add1614f51e652c9e84ddc4bc36208e7151220 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fran=C3=A7ois=20Honor=C3=A9?= Date: Tue, 10 Dec 2024 10:00:00 +0100 Subject: [PATCH 01/82] [IMP] mis_builder_budget: add active fields Add active field on mis.budget.by.account and mis.budget model and related views --- mis_builder_budget/models/mis_budget.py | 1 + mis_builder_budget/models/mis_budget_by_account.py | 1 + mis_builder_budget/views/mis_budget.xml | 13 +++++++++++++ mis_builder_budget/views/mis_budget_by_account.xml | 13 +++++++++++++ 4 files changed, 28 insertions(+) diff --git a/mis_builder_budget/models/mis_budget.py b/mis_builder_budget/models/mis_budget.py index 391f7c629..930a9ff8b 100644 --- a/mis_builder_budget/models/mis_budget.py +++ b/mis_builder_budget/models/mis_budget.py @@ -15,3 +15,4 @@ class MisBudget(models.Model): item_ids = fields.One2many( comodel_name="mis.budget.item", inverse_name="budget_id", copy=True ) + active = fields.Boolean(default=True, copy=False) diff --git a/mis_builder_budget/models/mis_budget_by_account.py b/mis_builder_budget/models/mis_budget_by_account.py index 16aa16fd0..5090e1a2f 100644 --- a/mis_builder_budget/models/mis_budget_by_account.py +++ b/mis_builder_budget/models/mis_budget_by_account.py @@ -16,3 +16,4 @@ class MisBudgetByAccount(models.Model): allow_items_overlap = fields.Boolean( help="If checked, overlap between budget items is allowed" ) + active = fields.Boolean(default=True, copy=False) diff --git a/mis_builder_budget/views/mis_budget.xml b/mis_builder_budget/views/mis_budget.xml index cc8ce241c..87f95871d 100644 --- a/mis_builder_budget/views/mis_budget.xml +++ b/mis_builder_budget/views/mis_budget.xml @@ -30,6 +30,12 @@ +
- - - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + + + + + + + - - - - - + + + + + + + + + + + + + + + + + - - - - - - - + + + + + + + + + + + + + + + + + + + + + + + - - - + + + + + + + + + - - - - - + + + + + + + + + + + + + + + + +
From 1a5cc9b728c975f93889936a07ef8b3b7723cc84 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Wed, 17 Sep 2025 13:58:33 +0000 Subject: [PATCH 20/82] [BOT] post-merge updates --- README.md | 2 +- mis_builder/README.rst | 2 +- mis_builder/__manifest__.py | 2 +- mis_builder/static/description/index.html | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 0947f226f..d4dd922ac 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ Available addons ---------------- addon | version | maintainers | summary --- | --- | --- | --- -[mis_builder](mis_builder/) | 18.0.1.2.5 | sbidoul | Build 'Management Information System' Reports and Dashboards +[mis_builder](mis_builder/) | 18.0.1.2.6 | sbidoul | Build 'Management Information System' Reports and Dashboards [mis_builder_budget](mis_builder_budget/) | 18.0.1.0.3 | sbidoul | Create budgets for MIS reports [mis_builder_demo](mis_builder_demo/) | 18.0.1.0.0 | sbidoul | Demo addon for MIS Builder diff --git a/mis_builder/README.rst b/mis_builder/README.rst index 8375ac4ef..81ddcb10d 100644 --- a/mis_builder/README.rst +++ b/mis_builder/README.rst @@ -11,7 +11,7 @@ MIS Builder !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - !! source digest: sha256:7cf01e6875ee79bf463f2a363645a17afda2e778c492d51304542d2b2447f31b + !! source digest: sha256:e6328cf9494a575f3403f255a87ea97ddb1413a1240253d85bc907032232c06b !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Production%2FStable-green.png diff --git a/mis_builder/__manifest__.py b/mis_builder/__manifest__.py index f3adcea6b..cc42ca6e2 100644 --- a/mis_builder/__manifest__.py +++ b/mis_builder/__manifest__.py @@ -3,7 +3,7 @@ { "name": "MIS Builder", - "version": "18.0.1.2.5", + "version": "18.0.1.2.6", "category": "Reporting", "summary": """ Build 'Management Information System' Reports and Dashboards diff --git a/mis_builder/static/description/index.html b/mis_builder/static/description/index.html index 426e4190c..c3da86dee 100644 --- a/mis_builder/static/description/index.html +++ b/mis_builder/static/description/index.html @@ -372,7 +372,7 @@

MIS Builder

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -!! source digest: sha256:7cf01e6875ee79bf463f2a363645a17afda2e778c492d51304542d2b2447f31b +!! source digest: sha256:e6328cf9494a575f3403f255a87ea97ddb1413a1240253d85bc907032232c06b !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->

Production/Stable License: AGPL-3 OCA/mis-builder Translate me on Weblate Try me on Runboat

This module allows you to build Management Information Systems From 912c8918e6be9346547cac969a11496b2a4e0316 Mon Sep 17 00:00:00 2001 From: Lois Rilo Date: Wed, 17 Sep 2025 11:26:41 +0200 Subject: [PATCH 21/82] [MIG/IMP] mis_builder: analytic_distribution_search removed in 18 analytic_distribution_search has been removed in v18 and it was set on purpose on mis_builder migration scripts in 16.0. I think we need to handle it as well in 18.0 migration. --- mis_builder/README.rst | 2 +- mis_builder/__manifest__.py | 2 +- .../migrations/18.0.1.3.0/post-migration.py | 40 +++++++++++++++++++ 3 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 mis_builder/migrations/18.0.1.3.0/post-migration.py diff --git a/mis_builder/README.rst b/mis_builder/README.rst index 81ddcb10d..0ed585106 100644 --- a/mis_builder/README.rst +++ b/mis_builder/README.rst @@ -763,7 +763,7 @@ promote its widespread use. Current `maintainer `__: -|maintainer-sbidoul| +|maintainer-sbidoul| This module is part of the `OCA/mis-builder `_ project on GitHub. diff --git a/mis_builder/__manifest__.py b/mis_builder/__manifest__.py index cc42ca6e2..e296e27ee 100644 --- a/mis_builder/__manifest__.py +++ b/mis_builder/__manifest__.py @@ -3,7 +3,7 @@ { "name": "MIS Builder", - "version": "18.0.1.2.6", + "version": "18.0.1.3.0", "category": "Reporting", "summary": """ Build 'Management Information System' Reports and Dashboards diff --git a/mis_builder/migrations/18.0.1.3.0/post-migration.py b/mis_builder/migrations/18.0.1.3.0/post-migration.py new file mode 100644 index 000000000..0aca6e58d --- /dev/null +++ b/mis_builder/migrations/18.0.1.3.0/post-migration.py @@ -0,0 +1,40 @@ +# Copyright 2025 ForgeFlow S.L. +# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). + +from openupgradelib import openupgrade + +from odoo.tools.safe_eval import safe_eval + + +@openupgrade.migrate() +def migrate(cr, version): + """Update the value of the analytic_domain field.""" + # Workaround to execute the migration script without errors + # see https://github.com/odoo/odoo/blob/2a839ef1ed09c36f27ce7536ca3052d9f65ceed9/odoo/modules/migration.py#L252-L256 + env = cr + for record in env["mis.report.instance.period"].search( + [("analytic_domain", "!=", False)] + ): + new_domain = _update_domain(record) + record.write({"analytic_domain": new_domain}) + + for record in env["mis.report.instance"].search([("analytic_domain", "!=", False)]): + new_domain = _update_domain(record) + record.write({"analytic_domain": new_domain}) + + +def _update_domain(record): + # analytic_distribution_search has been removed in v18 and it was set on purpose + # on mis_builder migration scripts in 16.0. + domain = safe_eval(record.analytic_domain) + new_domain = [] + for clause in domain: + if ( + isinstance(clause, list | tuple) + and clause[0] == "analytic_distribution_search" + ): + operator = clause[1] + value = clause[2] + clause = ("distribution_analytic_account_ids", operator, value) + new_domain.append(clause) + return new_domain From ff09ed23b6f989c66dfc2f634d74930e587e8a53 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Mon, 22 Sep 2025 15:56:08 +0000 Subject: [PATCH 22/82] [BOT] post-merge updates --- README.md | 2 +- mis_builder/README.rst | 4 ++-- mis_builder/static/description/index.html | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index d4dd922ac..5236fc144 100644 --- a/README.md +++ b/README.md @@ -50,7 +50,7 @@ Available addons ---------------- addon | version | maintainers | summary --- | --- | --- | --- -[mis_builder](mis_builder/) | 18.0.1.2.6 | sbidoul | Build 'Management Information System' Reports and Dashboards +[mis_builder](mis_builder/) | 18.0.1.3.0 | sbidoul | Build 'Management Information System' Reports and Dashboards [mis_builder_budget](mis_builder_budget/) | 18.0.1.0.3 | sbidoul | Create budgets for MIS reports [mis_builder_demo](mis_builder_demo/) | 18.0.1.0.0 | sbidoul | Demo addon for MIS Builder diff --git a/mis_builder/README.rst b/mis_builder/README.rst index 0ed585106..e12c666b1 100644 --- a/mis_builder/README.rst +++ b/mis_builder/README.rst @@ -11,7 +11,7 @@ MIS Builder !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! - !! source digest: sha256:e6328cf9494a575f3403f255a87ea97ddb1413a1240253d85bc907032232c06b + !! source digest: sha256:78ca0877d573203204b6daf311dc3321d22d0f4c39f486ac9f84fffdca9d50ef !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Production%2FStable-green.png @@ -763,7 +763,7 @@ promote its widespread use. Current `maintainer `__: -|maintainer-sbidoul| +|maintainer-sbidoul| This module is part of the `OCA/mis-builder `_ project on GitHub. diff --git a/mis_builder/static/description/index.html b/mis_builder/static/description/index.html index c3da86dee..fc141056c 100644 --- a/mis_builder/static/description/index.html +++ b/mis_builder/static/description/index.html @@ -372,7 +372,7 @@

MIS Builder

!! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -!! source digest: sha256:e6328cf9494a575f3403f255a87ea97ddb1413a1240253d85bc907032232c06b +!! source digest: sha256:78ca0877d573203204b6daf311dc3321d22d0f4c39f486ac9f84fffdca9d50ef !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->

Production/Stable License: AGPL-3 OCA/mis-builder Translate me on Weblate Try me on Runboat

This module allows you to build Management Information Systems From a8537a78b9a883a47594715cc6e71e0769d23b36 Mon Sep 17 00:00:00 2001 From: Joel Estrada Date: Mon, 28 Jul 2025 09:16:38 +0200 Subject: [PATCH 23/82] [IMP] mis_builder: Sort reports by sequence MT-10677 @moduon --- mis_builder/models/mis_report_instance.py | 2 ++ mis_builder/views/mis_report_instance.xml | 1 + 2 files changed, 3 insertions(+) diff --git a/mis_builder/models/mis_report_instance.py b/mis_builder/models/mis_report_instance.py index 6a02b25e4..f861fa387 100644 --- a/mis_builder/models/mis_report_instance.py +++ b/mis_builder/models/mis_report_instance.py @@ -488,8 +488,10 @@ def _compute_pivot_date(self): _name = "mis.report.instance" _description = "MIS Report Instance" + _order = "sequence, id" name = fields.Char(required=True, translate=True) + sequence = fields.Integer(default=10) description = fields.Char(related="report_id.description") date = fields.Date( string="Base date", help="Report base date " "(leave empty to use current date)" diff --git a/mis_builder/views/mis_report_instance.xml b/mis_builder/views/mis_report_instance.xml index 92749dbe5..d1f2c7df9 100644 --- a/mis_builder/views/mis_report_instance.xml +++ b/mis_builder/views/mis_report_instance.xml @@ -27,6 +27,7 @@ mis.report.instance +