diff --git a/report_qweb_operating_unit/README.rst b/report_qweb_operating_unit/README.rst new file mode 100644 index 0000000000..7eb756ecc5 --- /dev/null +++ b/report_qweb_operating_unit/README.rst @@ -0,0 +1,85 @@ +.. image:: https://odoo-community.org/readme-banner-image + :target: https://odoo-community.org/get-involved?utm_source=readme + :alt: Odoo Community Association + +=============================== +Qweb Report With Operating Unit +=============================== + +.. + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! source digest: sha256:15241c0b3e7fd452963ef2390802c16ff7d144796e7e14af19e7f0736200f986 + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/license-LGPL--3-blue.png + :target: http://www.gnu.org/licenses/lgpl-3.0-standalone.html + :alt: License: LGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Foperating--unit-lightgray.png?logo=github + :target: https://github.com/OCA/operating-unit/tree/19.0/report_qweb_operating_unit + :alt: OCA/operating-unit +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/operating-unit-19-0/operating-unit-19-0-report_qweb_operating_unit + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png + :target: https://runboat.odoo-community.org/builds?repo=OCA/operating-unit&target_branch=19.0 + :alt: Try me on Runboat + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module allows to use custom operating unit headers for any report +in Odoo + +**Table of contents** + +.. contents:: + :local: + +Bug Tracker +=========== + +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. + +Credits +======= + +Authors +------- + +* ForgeFlow S.L. +* Serpent Consulting Services Pvt. Ltd. + +Contributors +------------ + +- ForgeFlow S.L. +- Serpent Consulting Services Pvt. Ltd. +- Jarsa Sistemas +- Juany Davila + +Maintainers +----------- + +This module is maintained by the OCA. + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +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/operating-unit `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/report_qweb_operating_unit/__init__.py b/report_qweb_operating_unit/__init__.py new file mode 100644 index 0000000000..0650744f6b --- /dev/null +++ b/report_qweb_operating_unit/__init__.py @@ -0,0 +1 @@ +from . import models diff --git a/report_qweb_operating_unit/__manifest__.py b/report_qweb_operating_unit/__manifest__.py new file mode 100644 index 0000000000..25ac4dfe70 --- /dev/null +++ b/report_qweb_operating_unit/__manifest__.py @@ -0,0 +1,17 @@ +# Copyright 2017 ForgeFlow S.L. +# Copyright 2017 Serpent Consulting Services Pvt. Ltd. +# License LGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). + +{ + "name": "Qweb Report With Operating Unit", + "version": "19.0.1.0.0", + "category": "Reports/Qweb", + "license": "LGPL-3", + "author": "ForgeFlow S.L., " + "Serpent Consulting Services Pvt. Ltd.," + "Odoo Community Association (OCA)", + "website": "https://github.com/OCA/operating-unit", + "depends": ["operating_unit"], + "data": ["views/operating_unit_view.xml", "views/report_qweb_operating_unit.xml"], + "installable": True, +} diff --git a/report_qweb_operating_unit/i18n/es_MX.po b/report_qweb_operating_unit/i18n/es_MX.po new file mode 100644 index 0000000000..4d867e29a9 --- /dev/null +++ b/report_qweb_operating_unit/i18n/es_MX.po @@ -0,0 +1,213 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * report_qweb_operating_unit +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2020-02-19 16:13+0000\n" +"Last-Translator: Jesús Alan Ramos Rodríguez \n" +"Language-Team: none\n" +"Language: es_MX\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 3.10\n" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Company address block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Company details block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Operating Unit address block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Operating unit details block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Company tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the company address." +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the company details." +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the operating unit address." +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the operating unit details." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__report_footer +msgid "Footer text displayed at the bottom of all reports." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__operating_unit_details +msgid "Header text displayed at the top of all reports." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__is_operating_unit_details_empty +msgid "Is Operating Unit Details Empty" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Logo" +msgstr "Logo" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "" +"Operating\n" +" Unit tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model,name:report_qweb_operating_unit.model_operating_unit +msgid "Operating Unit" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__operating_unit_details +msgid "Operating Unit Details" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__report_header +msgid "Operating Unit Tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +msgid "Operating Unit tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__report_header +msgid "" +"Operating Unit tagline, which is included in a printed document's header or " +"footer (depending on the selected layout)." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__report_footer +msgid "Report Footer" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.view_operating_unit_form +msgid "Report Layout" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Tax ID" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "US12345671" +msgstr "" + +#~ msgid "" +#~ "" +#~ msgstr "" +#~ "" + +#~ msgid "" +#~ "" +#~ msgstr "" + +#~ msgid "" +#~ "" +#~ msgstr "" +#~ "" + +#~ msgid "" +#~ "" +#~ msgstr "" +#~ "" + +#~ msgid "Email:" +#~ msgstr "Correo electrónico:" + +#~ msgid "Mail:" +#~ msgstr "Correo electrónico:" + +#~ msgid "Phone:" +#~ msgstr "Teléfono:" + +#~ msgid "Tel:" +#~ msgstr "Tel:" + +#~ msgid "Web:" +#~ msgstr "Web:" diff --git a/report_qweb_operating_unit/i18n/it.po b/report_qweb_operating_unit/i18n/it.po new file mode 100644 index 0000000000..2271a50a16 --- /dev/null +++ b/report_qweb_operating_unit/i18n/it.po @@ -0,0 +1,178 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * report_qweb_operating_unit +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 17.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2024-12-03 11:06+0000\n" +"Last-Translator: mymage \n" +"Language-Team: none\n" +"Language: it\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 5.6.2\n" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Company address block" +msgstr "Blocco indirizzo azienda" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Company details block" +msgstr "Blocco dettagli azienda" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Operating Unit address block" +msgstr "Blocco indirizzo unità operativa" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Operating unit details block" +msgstr "Blocco dettagli unità operativa" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Company tagline" +msgstr "Slogan azienda" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the company address." +msgstr "Contiene l'indirizzo dell'azienda." + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the company details." +msgstr "Contiene i dettagli dell'azienda." + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the operating unit address." +msgstr "Contiene l'indirizzo dell'unità operativa." + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Contains the operating unit details." +msgstr "Contiene i dettagli dell'unità operativa." + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__report_footer +msgid "Footer text displayed at the bottom of all reports." +msgstr "Testo in calce visualizzato in fondo al resoconto." + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__operating_unit_details +msgid "Header text displayed at the top of all reports." +msgstr "Testo testata visualizzato sulla sommità di ogni resoconto." + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__is_operating_unit_details_empty +msgid "Is Operating Unit Details Empty" +msgstr "I dettagli dell'unità operativa sono vuoti" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Logo" +msgstr "Logo" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "" +"Operating\n" +" Unit tagline" +msgstr "" +"Slogan\n" +" unità operativa" + +#. module: report_qweb_operating_unit +#: model:ir.model,name:report_qweb_operating_unit.model_operating_unit +msgid "Operating Unit" +msgstr "Unità operativa" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__operating_unit_details +msgid "Operating Unit Details" +msgstr "Dettagli unità operativa" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__report_header +msgid "Operating Unit Tagline" +msgstr "Slogan unità operativa" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +msgid "Operating Unit tagline" +msgstr "Slogan unità operativa" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__report_header +msgid "" +"Operating Unit tagline, which is included in a printed document's header or " +"footer (depending on the selected layout)." +msgstr "" +"Slogan unità operativa, che è inclusa nella testata o a piè pagina del " +"documento stampato (in funzione del layout selezionato)." + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__report_footer +msgid "Report Footer" +msgstr "Piè pagina resoconto" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.view_operating_unit_form +msgid "Report Layout" +msgstr "Layout resoconto" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "Tax ID" +msgstr "Partita IVA" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +msgid "US12345671" +msgstr "US12345671" diff --git a/report_qweb_operating_unit/i18n/report_qweb_operating_unit.pot b/report_qweb_operating_unit/i18n/report_qweb_operating_unit.pot new file mode 100644 index 0000000000..1270a74bfc --- /dev/null +++ b/report_qweb_operating_unit/i18n/report_qweb_operating_unit.pot @@ -0,0 +1,210 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * report_qweb_operating_unit +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 18.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Company address block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Company details block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Operating Unit address block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Operating unit details block" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Company tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Contains the company address." +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Contains the company details." +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Contains the operating unit address." +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Contains the operating unit details." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__report_footer +msgid "Footer text displayed at the bottom of all reports." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__operating_unit_details +msgid "Header text displayed at the top of all reports." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__is_operating_unit_details_empty +msgid "Is Operating Unit Details Empty" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Logo" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "" +"Operating\n" +" Unit tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model,name:report_qweb_operating_unit.model_operating_unit +msgid "Operating Unit" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__operating_unit_details +msgid "Operating Unit Details" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__report_header +msgid "Operating Unit Tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +msgid "Operating Unit tagline" +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,help:report_qweb_operating_unit.field_operating_unit__report_header +msgid "" +"Operating Unit tagline, which is included in a printed document's header or " +"footer (depending on the selected layout)." +msgstr "" + +#. module: report_qweb_operating_unit +#: model:ir.model.fields,field_description:report_qweb_operating_unit.field_operating_unit__report_footer +msgid "Report Footer" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.view_operating_unit_form +msgid "Report Layout" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "Tax ID" +msgstr "" + +#. module: report_qweb_operating_unit +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bold_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_boxed_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_bubble_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_folder_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_standard_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_striped_ou +#: model_terms:ir.ui.view,arch_db:report_qweb_operating_unit.external_layout_wave_ou +msgid "US12345671" +msgstr "" diff --git a/report_qweb_operating_unit/models/__init__.py b/report_qweb_operating_unit/models/__init__.py new file mode 100644 index 0000000000..f5f887b83c --- /dev/null +++ b/report_qweb_operating_unit/models/__init__.py @@ -0,0 +1 @@ +from . import operating_unit diff --git a/report_qweb_operating_unit/models/operating_unit.py b/report_qweb_operating_unit/models/operating_unit.py new file mode 100644 index 0000000000..23fa3eaaf5 --- /dev/null +++ b/report_qweb_operating_unit/models/operating_unit.py @@ -0,0 +1,64 @@ +# Copyright 2024 NSI-SA +# License LGPL-3.0 or later (https://www.gnu.org/licenses/lgpl.html). +from odoo import api, fields, models +from odoo.tools import html2plaintext + + +class OperatingUnit(models.Model): + _inherit = "operating.unit" + + report_header = fields.Html( + string="Operating Unit Tagline", + translate=True, + compute="_compute_report_header", + store=True, + readonly=False, + help="Operating Unit tagline, which is included " + "in a printed document's header or footer " + "(depending on the selected layout).", + ) + report_footer = fields.Html( + translate=True, + compute="_compute_report_footer", + store=True, + readonly=False, + help="Footer text displayed at the bottom of all reports.", + ) + operating_unit_details = fields.Html( + translate=True, + compute="_compute_operating_unit_details", + store=True, + readonly=False, + help="Header text displayed at the top of all reports.", + ) + is_operating_unit_details_empty = fields.Boolean( + compute="_compute_empty_operating_unit_details" + ) + + @api.depends("company_id") + def _compute_report_header(self): + for operating_unit in self: + operating_unit.report_header = operating_unit.company_id.report_header + + @api.depends("company_id") + def _compute_report_footer(self): + for operating_unit in self: + operating_unit.report_footer = operating_unit.company_id.report_footer + + @api.depends("company_id") + def _compute_operating_unit_details(self): + for operating_unit in self: + operating_unit.operating_unit_details = ( + operating_unit.company_id.company_details + ) + + @api.depends("operating_unit_details") + def _compute_empty_operating_unit_details(self): + # In recent change when an html field is + # empty a

balise remains with a
in it, + # but when operating unit details is empty + # we want to put the info of the operating unit + for operating_unit in self: + operating_unit.is_operating_unit_details_empty = not html2plaintext( + operating_unit.operating_unit_details or "" + ) diff --git a/report_qweb_operating_unit/pyproject.toml b/report_qweb_operating_unit/pyproject.toml new file mode 100644 index 0000000000..4231d0cccb --- /dev/null +++ b/report_qweb_operating_unit/pyproject.toml @@ -0,0 +1,3 @@ +[build-system] +requires = ["whool"] +build-backend = "whool.buildapi" diff --git a/report_qweb_operating_unit/readme/CONTRIBUTORS.md b/report_qweb_operating_unit/readme/CONTRIBUTORS.md new file mode 100644 index 0000000000..0e9ebbf5b0 --- /dev/null +++ b/report_qweb_operating_unit/readme/CONTRIBUTORS.md @@ -0,0 +1,4 @@ +- ForgeFlow S.L. \<\> +- Serpent Consulting Services Pvt. Ltd. \<\> +- Jarsa Sistemas \<\> +- Juany Davila \<\> diff --git a/report_qweb_operating_unit/readme/DESCRIPTION.md b/report_qweb_operating_unit/readme/DESCRIPTION.md new file mode 100644 index 0000000000..76bb07bdad --- /dev/null +++ b/report_qweb_operating_unit/readme/DESCRIPTION.md @@ -0,0 +1,2 @@ +This module allows to use custom operating unit headers for any report +in Odoo diff --git a/report_qweb_operating_unit/static/description/icon.png b/report_qweb_operating_unit/static/description/icon.png new file mode 100644 index 0000000000..3a0328b516 Binary files /dev/null and b/report_qweb_operating_unit/static/description/icon.png differ diff --git a/report_qweb_operating_unit/static/description/index.html b/report_qweb_operating_unit/static/description/index.html new file mode 100644 index 0000000000..d19ee06cf8 --- /dev/null +++ b/report_qweb_operating_unit/static/description/index.html @@ -0,0 +1,434 @@ + + + + + +README.rst + + + +

+ + + +Odoo Community Association + +
+

Qweb Report With Operating Unit

+ +

Beta License: LGPL-3 OCA/operating-unit Translate me on Weblate Try me on Runboat

+

This module allows to use custom operating unit headers for any report +in Odoo

+

Table of contents

+ +
+

Bug Tracker

+

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.

+
+
+

Credits

+
+

Authors

+
    +
  • ForgeFlow S.L.
  • +
  • Serpent Consulting Services Pvt. Ltd.
  • +
+
+
+

Contributors

+ +
+
+

Maintainers

+

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/operating-unit project on GitHub.

+

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

+
+
+
+
+ + diff --git a/report_qweb_operating_unit/tests/__init__.py b/report_qweb_operating_unit/tests/__init__.py new file mode 100644 index 0000000000..580eccdc61 --- /dev/null +++ b/report_qweb_operating_unit/tests/__init__.py @@ -0,0 +1 @@ +from . import test_report_qweb_operating_unit diff --git a/report_qweb_operating_unit/tests/test_report_qweb_operating_unit.py b/report_qweb_operating_unit/tests/test_report_qweb_operating_unit.py new file mode 100644 index 0000000000..6ab7489848 --- /dev/null +++ b/report_qweb_operating_unit/tests/test_report_qweb_operating_unit.py @@ -0,0 +1,43 @@ +from unittest.mock import MagicMock + +from odoo.tools import is_html_empty + +from odoo.addons.operating_unit.tests.common import OperatingUnitCommon + + +class TestReportQwebOperatingUnit(OperatingUnitCommon): + @classmethod + def setUpClass(cls): + super().setUpClass() + cls.env.company.report_header = "Company report header" + cls.ou1.report_header = "OU report header" + cls.mock_user = MagicMock(wraps=cls.env.user) + cls.mock_user.__contains__ = lambda self, other: True + cls.mock_user.operating_unit_id = cls.ou1 + + def test_rendering(self): + for layout in ("standard", "striped", "bold", "boxed", "bubble"): + xmlid = f"web.external_layout_{layout}" + render_context = dict( + company=self.env.company, + o=self.env.user, + is_html_empty=is_html_empty, + ) + html = ( + self.env["ir.actions.report"] + ._render_template( + xmlid, + render_context, + ) + .decode("utf8") + ) + self.assertIn(self.env.company.report_header, html) + html = ( + self.env["ir.actions.report"] + ._render_template( + xmlid, + dict(render_context, o=self.mock_user), + ) + .decode("utf8") + ) + self.assertIn(self.ou1.report_header, html) diff --git a/report_qweb_operating_unit/views/operating_unit_view.xml b/report_qweb_operating_unit/views/operating_unit_view.xml new file mode 100644 index 0000000000..9705a532f3 --- /dev/null +++ b/report_qweb_operating_unit/views/operating_unit_view.xml @@ -0,0 +1,21 @@ + + + + operating.unit.form + operating.unit + + +
+ + + + + + + + + +
+
+
+
diff --git a/report_qweb_operating_unit/views/report_qweb_operating_unit.xml b/report_qweb_operating_unit/views/report_qweb_operating_unit.xml new file mode 100644 index 0000000000..6a5eccff55 --- /dev/null +++ b/report_qweb_operating_unit/views/report_qweb_operating_unit.xml @@ -0,0 +1,782 @@ + + + + + + + + + + +