From 56640d9e50e9dc69e0d1ec3e742dd6e427bf678e Mon Sep 17 00:00:00 2001 From: Sylvain LE GAL Date: Mon, 18 May 2026 21:34:24 +0200 Subject: [PATCH 1/4] [IMP] account_invoice_margin: set new option 'optional' hide to margin fields on tree views. Rational: this field is usefull to be in the tree. However, it is not usefull for all user in a day to day basis. put optional='hide' to make the invoice and invoice lines list tree view lighter. --- .../views/account_invoice_margin_view.xml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/account_invoice_margin/views/account_invoice_margin_view.xml b/account_invoice_margin/views/account_invoice_margin_view.xml index d640de73d..5070c0fdb 100644 --- a/account_invoice_margin/views/account_invoice_margin_view.xml +++ b/account_invoice_margin/views/account_invoice_margin_view.xml @@ -18,12 +18,12 @@ /> @@ -65,12 +65,12 @@ From 419125e7b36a4baa726f2ae027bd7835d22f0cd5 Mon Sep 17 00:00:00 2001 From: Sylvain LE GAL Date: Tue, 7 Jul 2026 16:56:50 +0200 Subject: [PATCH 2/4] [FIX] account_invoice_margin : prevent to display useless fields on account.move.lines (when not related to out invoices) --- account_invoice_margin/views/account_invoice_margin_view.xml | 3 +++ 1 file changed, 3 insertions(+) diff --git a/account_invoice_margin/views/account_invoice_margin_view.xml b/account_invoice_margin/views/account_invoice_margin_view.xml index 5070c0fdb..260ba31fd 100644 --- a/account_invoice_margin/views/account_invoice_margin_view.xml +++ b/account_invoice_margin/views/account_invoice_margin_view.xml @@ -15,16 +15,19 @@ name="purchase_price" optional="show" groups="account_invoice_margin.group_account_invoice_margin_security" + attrs="{'column_invisible': [('parent.move_type', 'not in', ('out_invoice', 'out_refund'))]}" /> From 2aecdb822637e5aad87fde63e2ccdc7838f89476 Mon Sep 17 00:00:00 2001 From: Sylvain LE GAL Date: Tue, 7 Jul 2026 16:58:35 +0200 Subject: [PATCH 3/4] [FIX] account_invoice_margin : do not display margin in move tree views, if there are not out invoices --- account_invoice_margin/views/account_invoice_margin_view.xml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/account_invoice_margin/views/account_invoice_margin_view.xml b/account_invoice_margin/views/account_invoice_margin_view.xml index 260ba31fd..66bc65206 100644 --- a/account_invoice_margin/views/account_invoice_margin_view.xml +++ b/account_invoice_margin/views/account_invoice_margin_view.xml @@ -62,7 +62,7 @@ account.move - + Date: Tue, 4 Aug 2026 14:14:01 +0200 Subject: [PATCH 4/4] [FIX] account_invoice_margin: remove scale image in description, that make whl generation failing --- account_invoice_margin/README.rst | 10 ++--- account_invoice_margin/readme/DESCRIPTION.rst | 4 -- .../static/description/index.html | 42 +++++++++++-------- 3 files changed, 30 insertions(+), 26 deletions(-) diff --git a/account_invoice_margin/README.rst b/account_invoice_margin/README.rst index e6f26149b..c0bf0409b 100644 --- a/account_invoice_margin/README.rst +++ b/account_invoice_margin/README.rst @@ -1,3 +1,7 @@ +.. image:: https://odoo-community.org/readme-banner-image + :target: https://odoo-community.org/get-involved?utm_source=readme + :alt: Odoo Community Association + ====================== Account Invoice Margin ====================== @@ -13,7 +17,7 @@ Account Invoice Margin .. |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/licence-AGPL--3-blue.png +.. |badge2| image:: https://img.shields.io/badge/license-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%2Fmargin--analysis-lightgray.png?logo=github @@ -35,14 +39,10 @@ The new information is available: * on the invoice form view .. figure:: https://raw.githubusercontent.com/OCA/margin-analysis/16.0/account_invoice_margin/static/description/account_invoice_form.png - :scale: 80 % - :alt: Invoice Tree View * and on the invoice tree view .. figure:: https://raw.githubusercontent.com/OCA/margin-analysis/16.0/account_invoice_margin/static/description/account_invoice_tree.png - :scale: 80 % - :alt: Invoice Tree View **Table of contents** diff --git a/account_invoice_margin/readme/DESCRIPTION.rst b/account_invoice_margin/readme/DESCRIPTION.rst index 7042708e2..d0259b2cf 100644 --- a/account_invoice_margin/readme/DESCRIPTION.rst +++ b/account_invoice_margin/readme/DESCRIPTION.rst @@ -5,11 +5,7 @@ The new information is available: * on the invoice form view .. figure:: ../static/description/account_invoice_form.png - :scale: 80 % - :alt: Invoice Tree View * and on the invoice tree view .. figure:: ../static/description/account_invoice_tree.png - :scale: 80 % - :alt: Invoice Tree View diff --git a/account_invoice_margin/static/description/index.html b/account_invoice_margin/static/description/index.html index 3ef182f72..98c1a5048 100644 --- a/account_invoice_margin/static/description/index.html +++ b/account_invoice_margin/static/description/index.html @@ -1,18 +1,18 @@ - -Account Invoice Margin +README.rst -
-

Account Invoice Margin

+
+ + +Odoo Community Association + +
+

Account Invoice Margin

-

Production/Stable License: AGPL-3 OCA/margin-analysis Translate me on Weblate Try me on Runboat

+

Production/Stable License: AGPL-3 OCA/margin-analysis Translate me on Weblate Try me on Runboat

This module allows to show sales margin in invoices.

The new information is available:

  • on the invoice form view
-Invoice Tree View +https://raw.githubusercontent.com/OCA/margin-analysis/16.0/account_invoice_margin/static/description/account_invoice_form.png
  • and on the invoice tree view
-Invoice Tree View +https://raw.githubusercontent.com/OCA/margin-analysis/16.0/account_invoice_margin/static/description/account_invoice_tree.png

Table of contents

@@ -398,7 +403,7 @@

Account Invoice Margin

-

Usage

+

Usage

This module also adds a security group.

  1. To activate it go to user and active “Show Invoice Margin” in @@ -406,7 +411,7 @@

    Usage

-

Bug Tracker

+

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 @@ -414,16 +419,16 @@

Bug Tracker

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

-

Credits

+

Credits

-

Authors

+

Authors

  • Tecnativa
  • GRAP
-

Contributors

+

Contributors

-

Maintainers

+

Maintainers

This module is maintained by the OCA.

-Odoo Community Association + +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.

@@ -461,5 +468,6 @@

Maintainers

+