Maintainers
+Maintainers
This module is maintained by the OCA.
@@ -1184,6 +1179,5 @@ diff --git a/mis_builder/README.rst b/mis_builder/README.rst index 823dc3906..8a5930929 100644 --- a/mis_builder/README.rst +++ b/mis_builder/README.rst @@ -1,7 +1,3 @@ -.. image:: https://odoo-community.org/readme-banner-image - :target: https://odoo-community.org/get-involved?utm_source=readme - :alt: Odoo Community Association - =========== MIS Builder =========== @@ -17,7 +13,7 @@ MIS Builder .. |badge1| image:: https://img.shields.io/badge/maturity-Production%2FStable-green.png :target: https://odoo-community.org/page/development-status :alt: Production/Stable -.. |badge2| image:: https://img.shields.io/badge/license-AGPL--3-blue.png +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fmis--builder-lightgray.png?logo=github diff --git a/mis_builder/__manifest__.py b/mis_builder/__manifest__.py index 492413377..b831aaf3e 100644 --- a/mis_builder/__manifest__.py +++ b/mis_builder/__manifest__.py @@ -3,7 +3,7 @@ { "name": "MIS Builder", - "version": "18.0.1.7.3", + "version": "18.0.2.0.0", "category": "Reporting", "summary": """ Build 'Management Information System' Reports and Dashboards @@ -13,7 +13,6 @@ "depends": [ "account", "board", - "report_xlsx", # OCA/reporting-engine "date_range", # OCA/server-ux ], "data": [ @@ -26,7 +25,6 @@ "security/ir.model.access.csv", "security/mis_builder_security.xml", "report/mis_report_instance_qweb.xml", - "report/mis_report_instance_xlsx.xml", ], "assets": { "web.assets_backend": [ diff --git a/mis_builder/migrations/18.0.2.0.0/pre-migration.py b/mis_builder/migrations/18.0.2.0.0/pre-migration.py new file mode 100644 index 000000000..33bac7a12 --- /dev/null +++ b/mis_builder/migrations/18.0.2.0.0/pre-migration.py @@ -0,0 +1,36 @@ +import logging + +from openupgradelib import openupgrade + +_logger = logging.getLogger(__name__) + +xmlid_renames = [ + ("mis_builder.xls_export", "mis_builder_report_xlsx.xls_export"), +] + + +@openupgrade.migrate() +def migrate(env, version): + env.cr.execute(""" + SELECT count(*) + FROM ir_module_module + WHERE name = 'mis_builder_report_xlsx'""") + if env.cr.fetchone()[0] == 0: + _logger.error( + "Unable to found the module mis_builder_report_xlsx.\n" + " The module mis_builder has been refactored" + " and splitted into another module named" + " 'mis_builder_report_xlsx'." + " If you don't get this module in your addons path" + " the feature to export in XLSX will be lost.\n" + " More information:" + " https://github.com/OCA/mis-builder/pull/728" + ) + openupgrade.logged_query( + env.cr, + """ + UPDATE ir_module_module + SET state='to upgrade' + WHERE name = 'mis_builder_report_xlsx' AND state='uninstalled'""", + ) + openupgrade.rename_xmlids(env.cr, xmlid_renames) diff --git a/mis_builder/models/mis_report_instance.py b/mis_builder/models/mis_report_instance.py index 640c6cf37..64c735213 100644 --- a/mis_builder/models/mis_report_instance.py +++ b/mis_builder/models/mis_report_instance.py @@ -792,12 +792,6 @@ def print_pdf(self): .report_action(self, data=dict(dummy=True)) # required to propagate context ) - def export_xls(self): - self.ensure_one() - return self.env.ref("mis_builder.xls_export").report_action( - self, data=dict(dummy=True) - ) # required to propagate context - def display_settings(self): assert len(self.ids) <= 1 view_id = self.env.ref("mis_builder.mis_report_instance_view_form") diff --git a/mis_builder/models/mis_report_style.py b/mis_builder/models/mis_report_style.py index 287984d0b..88444ed3b 100644 --- a/mis_builder/models/mis_report_style.py +++ b/mis_builder/models/mis_report_style.py @@ -74,16 +74,6 @@ def check_positive_val(self): ("xx-large", "xx-large"), ] - _font_size_to_xlsx_size = { - "medium": 11, - "xx-small": 5, - "x-small": 7, - "small": 9, - "large": 13, - "x-large": 15, - "xx-large": 17, - } - # style name name = fields.Char(string="Style name", required=True) @@ -309,36 +299,6 @@ def compare_and_render( delta_r = self.render(lang, delta_style, delta_type, delta, sign="+") return delta, delta_r, delta_style, delta_type - @api.model - def to_xlsx_style(self, var_type, props, no_indent=False): - xlsx_attributes = [ - ("italic", props.font_style == "italic"), - ("bold", props.font_weight == "bold"), - ("font_size", self._font_size_to_xlsx_size.get(props.font_size, 11)), - ("font_color", props.color), - ("bg_color", props.background_color), - ] - if var_type == TYPE_NUM: - num_format = "#,##0" - if props.dp: - num_format += "." - num_format += "0" * props.dp - if props.prefix: - num_format = f'"{props.prefix} "{num_format}' - if props.suffix: - num_format = f'{num_format}" {props.suffix}"' - xlsx_attributes.append(("num_format", num_format)) - elif var_type == TYPE_PCT: - num_format = "0" - if props.dp: - num_format += "." - num_format += "0" * props.dp - num_format += "%" - xlsx_attributes.append(("num_format", num_format)) - if props.indent_level is not None and not no_indent: - xlsx_attributes.append(("indent", props.indent_level)) - return dict([a for a in xlsx_attributes if a[1] is not None]) - @api.model def to_css_style(self, props, no_indent=False): css_attributes = [ diff --git a/mis_builder/report/__init__.py b/mis_builder/report/__init__.py index 6f814d60b..dbe8a08b8 100644 --- a/mis_builder/report/__init__.py +++ b/mis_builder/report/__init__.py @@ -2,4 +2,3 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from . import mis_report_instance_qweb -from . import mis_report_instance_xlsx diff --git a/mis_builder/static/description/index.html b/mis_builder/static/description/index.html index b43076c19..931fceef3 100644 --- a/mis_builder/static/description/index.html +++ b/mis_builder/static/description/index.html @@ -3,7 +3,7 @@
-This module allows you to build Management Information Systems dashboards. Such style of reports presents KPI in rows and time periods in columns. Reports mainly fetch data from account moves, but can also @@ -446,7 +441,7 @@
Your preferred way to install addons will work with MIS Builder.
An easy way to install it with all its dependencies is using pip:
To configure this module, you need to:
A typical extension is to provide a mechanism to filter reports on analytic dimensions or operational units. To implement this, you can override _get_additional_move_line_filter and _get_additional_filter @@ -495,7 +490,7 @@
The mis_builder
roadmap
and known
@@ -503,11 +498,11 @@ Known issues / Roadmap
can be found on GitHub.
Bugfixes
Bugfixes
Features
Features
Bugfixes
Bugfixes
Bugfixes
Features
Bugfixes
Bugfixes
Bugfixes
Features
Bugfixes
Bugfixes
Bugfixes
Features
Features
Features
Features
Dynamic analytic filters in report preview are not yet available in 11,
this requires an update to the JS widget that proved difficult to
@@ -873,7 +868,7 @@ 12.0.3.3.0 (2019-01-26)
analytic_account_id field.
New features:
Bug fix:
Bug fix:
New features:
Part of the work for this release has been done at the Sorrento sprint April 26-29, 2016. The rest (ie a major refactoring) has been done in the weeks after.
@@ -1088,7 +1083,7 @@Bugs are tracked on GitHub Issues. In case of trouble, please check there if your issue has already been reported. If you spotted it first, help us to smash it by providing a detailed and welcomed @@ -1126,15 +1121,15 @@
Do not contact contributors directly about support or help with technical issues.