Skip to content

[17.0][ADD] brand_external_report_layout - #316

Open
Kuczka wants to merge 4 commits into
OCA:17.0from
Kuczka:17.0-fix-brand_external_report_layout-odoo17-compat
Open

[17.0][ADD] brand_external_report_layout#316
Kuczka wants to merge 4 commits into
OCA:17.0from
Kuczka:17.0-fix-brand_external_report_layout-odoo17-compat

Conversation

@Kuczka

@Kuczka Kuczka commented Jul 23, 2026

Copy link
Copy Markdown

This PR ports the brand_external_report_layout module to Odoo 17.0.

The 18.0 version references several report layout templates that do not
exist in Odoo 17.0 (external_layout_bubble, external_layout_striped,
external_layout_wave, external_layout_folder). These have been removed,
leaving the module compatible with the standard Odoo 17.0 layouts:
standard, boxed, and bold.

Tested and working on odoo.sh with Odoo 17.0 Enterprise.

I have read the CLA Document and I hereby sign the CLA

Port of the 18.0 module with Odoo 18-only layouts removed
(bubble, striped, wave, folder) to ensure compatibility with
Odoo 17.0 report layout templates.
Port of the 18.0 module with Odoo 18-only layouts removed
(bubble, striped, wave, folder) to ensure compatibility with
Odoo 17.0 report layout templates.
@OCA-git-bot OCA-git-bot added series:17.0 mod:brand_external_report_layout Module brand_external_report_layout labels Jul 23, 2026
@Kuczka

Kuczka commented Jul 23, 2026

Copy link
Copy Markdown
Author

The test failure in partner_brand.tests.test_partner_brand.test_empty_brand_logo
is a pre-existing issue in the OCA repository and is unrelated to this PR.
Our contribution only adds the brand_external_report_layout module, which
passes all 8 of its own tests successfully (as shown in the log:
brand_external_report_layout: 8 tests 0.50s 289 queries).

@rvalyi @zeroheure would you be able to review this? This ports brand_external_report_layout to 17.0.


1. Go to Settings \> Users & Companies \> Brands
2. Add a new brand or select an existing one
3. Enter brand information and select the a layout

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

typo : remove the a

Comment on lines +1 to +19
To simplify the customization of the external layout we replaced the
variable company that odoo compute in the external_layout view by the
object brand.

With this module, all custom layouts will display brand information out
of the box.

This was possible and easy to implement as the company and the brand
models inherit from partner model and share the same informational
fields.

The computed variable company is used to set report header and footer.
It's not meant to be used in the report business logic itself. But in
that case (if a custom layout use the variable company for some-reason
other then header and footer) this module can cause an issue because the
used field can be missing in the brand model or not correctly set.

In this case, we recommend to always use document field company for this
use-end.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is not a roadmap, rather a technical description. Shoudl be in the DESCRIPTION.md file. I suggest to add a title like "How it works"

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok

Comment on lines +1 to +2
This module allows you to have a different layout by brand for your
external reports.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May be "Choose a layout for you brands in external reports."
(we know it's a module that allows us to do something :-)

{
"name": "Brand External Report Layout",
"summary": """
This module allows you to have a different layout by brand for your

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

May be "Easily choose a layout for each of your brands in external reports."

#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 18.0\n"

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Odoo 17 or Odoo 18 ?

- Move ROADMAP.md technical description into DESCRIPTION.md
- Update DESCRIPTION.md summary line per maintainer request
- Fix Project-Id-Version from 18.0 to 17.0 in .pot file
@Kuczka

Kuczka commented Jul 28, 2026

Copy link
Copy Markdown
Author

Thanks @zeroheure made some changes.

ROADMAP.md → content moved to DESCRIPTION.md, file is now empty
DESCRIPTION.md → first line changed to "Choose a layout for your brands in external reports." with the technical description appended below
brand_external_report_layout.pot → Project-Id-Version changed from 18.0 to 17.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

mod:brand_external_report_layout Module brand_external_report_layout series:17.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants