Skip to content

Latest commit

 

History

History
91 lines (67 loc) · 3.83 KB

README.rst

File metadata and controls

91 lines (67 loc) · 3.83 KB

Py3o Report Engine: Update Indices (TOC, etc.)

Beta License: AGPL-3 OCA/reporting-engine Translate me on Weblate Try me on Runboat

This module fills in the document indexes (e.g. a Table of Content) in a generated py3o document.

This is to work around the missing feature first reported in 2012: https://bugs.documentfoundation.org/show_bug.cgi?id=44448

It uses the workaround given in https://ask.libreoffice.org/t/update-toc-via-command-line/52518 and other similar threads.

Note that to work, the macro has to be installed in libreoffice first. This is done at module install. It assumes the macro files are stored at ~/.config/libreoffice/4/user/basic/Standard. If it fails, the function can be manually called with the real path using: self.env["py3o.report"]._install_update_index_macro(real_path) Make sure that this is correct as most failure paths of the macro application are silent.

Once this is done, py3o templates have an "has index" boolean. If set, the macro is applied after generation (and before pdf conversion) to update all indices.

Table of contents

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 feedback.

Do not contact contributors directly about support or help with technical issues.

  • Lambdao

This module is maintained by the OCA.

Odoo Community Association

OCA, or the Odoo Community Association, is a nonprofit organization whose mission is to support the collaborative development of Odoo features and promote its widespread use.

This module is part of the OCA/reporting-engine project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.