Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
28 commits
Select commit Hold shift + click to select a range
d5e6769
[ADD] website_sale_b2x_alt_price: display B2{B,C} complementary price
Aug 7, 2020
4da2304
[FIX] website_sale_b2x_alt_price: l10n resilient tests
Aug 14, 2020
0588506
Added translation using Weblate (French)
ypapouin Nov 23, 2020
8ca348e
Added translation using Weblate (Catalan)
claudiagn Jan 20, 2021
65bae82
[IMP] website_sale_b2x_alt_price: black, isort
CarlosRoca13 Feb 24, 2021
83e73d0
[MIG] website_sale_b2x_alt_price: Migration to v13.0
CarlosRoca13 Feb 24, 2021
8a17077
[IMP] website_sale_b2x_alt_price: black, isort, prettier
CarlosRoca13 May 25, 2022
e6d6693
[MIG] website_sale_b2x_alt_price: Migration to 15.0
CarlosRoca13 May 25, 2022
6ac4908
[IMP] website_sale_b2x_alt_price: Add price without tax to the quotat…
pilarvargas-tecnativa Apr 25, 2023
1d46964
Update translation files
weblate Apr 29, 2023
130b632
Translated using Weblate (Spanish)
Ivorra78 Jul 5, 2023
dbccaf1
[IMP] website_sale_b2x_alt_price: test performance improvement
josep-tecnativa Oct 18, 2023
0ae356d
[IMP] website_sale_b2x_alt_price: pre-commit stuff
carlos-lopez-tecnativa Jul 30, 2024
382993a
[MIG] website_sale_b2x_alt_price: Migration to 17.0
carlos-lopez-tecnativa Jul 31, 2024
320e87d
Added translation using Weblate (Italian)
mymage Aug 14, 2024
b17ab28
[IMP] website_sale_b2x_alt_price: pre-commit auto fixes
carlos-lopez-tecnativa Jan 29, 2025
74a2455
[MIG] website_sale_b2x_alt_price: Migration to version 18.0
carlos-lopez-tecnativa Jan 29, 2025
34872f3
Update translation files
weblate Feb 5, 2025
eb052d2
Added translation using Weblate (Portuguese (Brazil))
marcelsavegnago Jun 30, 2025
e17d3de
Translated using Weblate (Portuguese (Brazil))
weblate Feb 25, 2026
4383a2c
Translated using Weblate (Spanish)
weblate Feb 25, 2026
f5f3155
Translated using Weblate (French)
weblate Feb 25, 2026
fd18b0f
Translated using Weblate (Catalan)
weblate Feb 25, 2026
d29d111
Translated using Weblate (Italian)
weblate Feb 25, 2026
6674221
Translated using Weblate (Spanish)
Ed-Spain Apr 22, 2026
71ac32c
Reformatted after template update
SirPyTech Apr 24, 2026
8abd920
[MIG] website_sale_b2x_alt_price: Migration to version 19.0
carlos-lopez-tecnativa Aug 7, 2026
45e9994
[BUILD] website_sale_tax_selection> Mark as a rebel module
carlos-lopez-tecnativa Aug 7, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .copier-answers.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,8 @@ odoo_version: 19.0
org_name: Odoo Community Association (OCA)
org_slug: OCA
postgres_image: ''
rebel_module_groups: []
rebel_module_groups:
- website_sale_tax_selection
repo_description: e-commerce
repo_name: e-commerce
repo_slug: e-commerce
Expand Down
11 changes: 11 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,17 @@ jobs:
matrix:
include:
- container: ghcr.io/oca/oca-ci/py3.10-odoo19.0:latest
include: "website_sale_tax_selection"
name: test with Odoo
- container: ghcr.io/oca/oca-ci/py3.10-ocb19.0:latest
include: "website_sale_tax_selection"
name: test with OCB
makepot: "true"
- container: ghcr.io/oca/oca-ci/py3.10-odoo19.0:latest
exclude: "website_sale_tax_selection"
name: test with Odoo
- container: ghcr.io/oca/oca-ci/py3.10-ocb19.0:latest
exclude: "website_sale_tax_selection"
name: test with OCB
makepot: "true"
services:
Expand All @@ -54,6 +63,8 @@ jobs:
ports:
- 5432:5432
env:
INCLUDE: "${{ matrix.include }}"
EXCLUDE: "${{ matrix.exclude }}"
OCA_ENABLE_CHECKLOG_ODOO: "1"
steps:
- uses: actions/checkout@v4
Expand Down
151 changes: 151 additions & 0 deletions website_sale_b2x_alt_price/README.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,151 @@
.. image:: https://odoo-community.org/readme-banner-image
:target: https://odoo-community.org/get-involved?utm_source=readme
:alt: Odoo Community Association

=================================================
Alternative (un)taxed prices display on eCommerce
=================================================

..
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
!! source digest: sha256:eb91812b36fc9a9f813e711ffba2a7da074bd76b7ca78f5174e46c103ca4783b
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

.. |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-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%2Fe--commerce-lightgray.png?logo=github
:target: https://github.com/OCA/e-commerce/tree/19.0/website_sale_b2x_alt_price
:alt: OCA/e-commerce
.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png
:target: https://translation.odoo-community.org/projects/e-commerce-19-0/e-commerce-19-0-website_sale_b2x_alt_price
: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/e-commerce&target_branch=19.0
:alt: Try me on Runboat

|badge1| |badge2| |badge3| |badge4| |badge5|

This module takes into account if your eCommerce is in B2B or B2C mode,
and displays the alternative pricing next to the main one.

For example, if your website is B2B (main price is without taxes), you
would see it similar to this:

|b2b-features|

If your website is B2C (main price is with taxes), then it looks like
this:

|b2c-features|

It also displays the alternative price, including discounts, updated
automatically when the user is choosing alternatives in the product
detail page:

|details-features|

.. |b2b-features| image:: https://raw.githubusercontent.com/OCA/e-commerce/19.0/website_sale_b2x_alt_price/static/description/b2b-features.png
.. |b2c-features| image:: https://raw.githubusercontent.com/OCA/e-commerce/19.0/website_sale_b2x_alt_price/static/description/b2c-features.png
.. |details-features| image:: https://raw.githubusercontent.com/OCA/e-commerce/19.0/website_sale_b2x_alt_price/static/description/details-features.gif

**Table of contents**

.. contents::
:local:

Configuration
=============

To choose if you want to display or not the alternative price in the
website products list, just enable or disable the feature from the
"Customize" tab of the web editor. This can be done independently per
website:

|toggle-list|

You can also toggle the behavior similarly in the product details page.
This can also be done independently per website:

|toggle-detail|

.. |toggle-list| image:: https://raw.githubusercontent.com/OCA/e-commerce/19.0/website_sale_b2x_alt_price/static/description/toggle-list.png
.. |toggle-detail| image:: https://raw.githubusercontent.com/OCA/e-commerce/19.0/website_sale_b2x_alt_price/static/description/toggle-detail.png

Usage
=====

To use this module, you need to:

1. Create a product.
2. Set some customer taxes on it.
3. Publish it.
4. Go see it on your website. It will display the alternative price.

Known issues / Roadmap
======================

- Computing this requires 1 or 2 extra calls to ``taxes.compute_all()``
per product. This could be expensive in terms of performance, but the
truth is that it is also not very optimized upstream in Odoo. Maybe
optimize this part in Odoo and in this module? Or maybe apply some
hack to avoid recomputing this? Maybe cache calls to that method? Is
it really a problem in the Real World®?

Bug Tracker
===========

Bugs are tracked on `GitHub Issues <https://github.com/OCA/e-commerce/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 <https://github.com/OCA/e-commerce/issues/new?body=module:%20website_sale_b2x_alt_price%0Aversion:%2019.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.

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

Credits
=======

Authors
-------

* Tecnativa

Contributors
------------

- `Tecnativa <https://www.tecnativa.com/>`__:

- Jairo Llopis
- Carlos Roca
- Carlos López

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.

.. |maintainer-Yajo| image:: https://github.com/Yajo.png?size=40px
:target: https://github.com/Yajo
:alt: Yajo

Current `maintainer <https://odoo-community.org/page/maintainer-role>`__:

|maintainer-Yajo|

This module is part of the `OCA/e-commerce <https://github.com/OCA/e-commerce/tree/19.0/website_sale_b2x_alt_price>`_ project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.
1 change: 1 addition & 0 deletions website_sale_b2x_alt_price/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
from . import models
29 changes: 29 additions & 0 deletions website_sale_b2x_alt_price/__manifest__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# Copyright 2020 Jairo Llopis - Tecnativa
# License LGPL-3.0 or later (https://www.gnu.org/licenses/lgpl).
{
"name": "Alternative (un)taxed prices display on eCommerce",
"summary": "Display prices with(out) taxes in eCommerce, complementing normal mode",
"version": "19.0.1.0.0",
"development_status": "Production/Stable",
"category": "Website",
"website": "https://github.com/OCA/e-commerce",
"author": "Tecnativa, Odoo Community Association (OCA)",
"maintainers": ["Yajo"],
"license": "LGPL-3",
"application": False,
"installable": True,
"depends": ["website_sale"],
"data": ["templates/product.xml"],
"assets": {
"web.assets_frontend": [
"/website_sale_b2x_alt_price/static/src/js/product_configurator_mixin.esm.js",
],
"website.website_builder_assets": [
"/website_sale_b2x_alt_price/static/src/website_builder/product_page_option.xml",
],
"web.assets_tests": [
"/website_sale_b2x_alt_price/static/tests/tours/b2b.esm.js",
"/website_sale_b2x_alt_price/static/tests/tours/b2c.esm.js",
],
},
}
43 changes: 43 additions & 0 deletions website_sale_b2x_alt_price/i18n/ca.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * website_sale_b2x_alt_price
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 12.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-02-25 11:25+0000\n"
"PO-Revision-Date: 2026-02-25 07:30+0000\n"
"Last-Translator: Anonymous <noreply@weblate.org>\n"
"Language-Team: none\n"
"Language: ca\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.15.2\n"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (with taxes)</small>"
msgstr ""

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (without taxes)</small>"
msgstr ""

#. module: website_sale_b2x_alt_price
#: model:ir.model,name:website_sale_b2x_alt_price.model_product_template
msgid "Product"
msgstr ""

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "with taxes"
msgstr "amb taxes"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "without taxes"
msgstr "sense taxes"
43 changes: 43 additions & 0 deletions website_sale_b2x_alt_price/i18n/es.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * website_sale_b2x_alt_price
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 12.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-02-25 11:25+0000\n"
"PO-Revision-Date: 2026-04-22 12:30+0000\n"
"Last-Translator: Ed-Spain <eduamoros@gmail.com>\n"
"Language-Team: \n"
"Language: es\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n != 1;\n"
"X-Generator: Weblate 5.15.2\n"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (with taxes)</small>"
msgstr "<small> (con impuestos)</small>"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (without taxes)</small>"
msgstr "<small> (sin impuestos)</small>"

#. module: website_sale_b2x_alt_price
#: model:ir.model,name:website_sale_b2x_alt_price.model_product_template
msgid "Product"
msgstr "Producto"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "with taxes"
msgstr "con impuestos"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "without taxes"
msgstr "sin impuestos"
43 changes: 43 additions & 0 deletions website_sale_b2x_alt_price/i18n/fr.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,43 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * website_sale_b2x_alt_price
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 12.0\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2021-02-25 11:25+0000\n"
"PO-Revision-Date: 2026-02-25 07:29+0000\n"
"Last-Translator: Anonymous <noreply@weblate.org>\n"
"Language-Team: none\n"
"Language: fr\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=n > 1;\n"
"X-Generator: Weblate 5.15.2\n"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (with taxes)</small>"
msgstr ""

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (without taxes)</small>"
msgstr ""

#. module: website_sale_b2x_alt_price
#: model:ir.model,name:website_sale_b2x_alt_price.model_product_template
msgid "Product"
msgstr ""

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "with taxes"
msgstr "avec taxes"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "without taxes"
msgstr "sans taxes"
42 changes: 42 additions & 0 deletions website_sale_b2x_alt_price/i18n/it.po
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Translation of Odoo Server.
# This file contains the translation of the following modules:
# * website_sale_b2x_alt_price
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 17.0\n"
"Report-Msgid-Bugs-To: \n"
"PO-Revision-Date: 2026-02-25 07:30+0000\n"
"Last-Translator: Anonymous <noreply@weblate.org>\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.15.2\n"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (with taxes)</small>"
msgstr "<small> (con imposte)</small>"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.sale_order_portal_template
msgid "<small> (without taxes)</small>"
msgstr "<small> (senza imposte)</small>"

#. module: website_sale_b2x_alt_price
#: model:ir.model,name:website_sale_b2x_alt_price.model_product_template
msgid "Product"
msgstr "Prodotto"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "with taxes"
msgstr "tasse incluse"

#. module: website_sale_b2x_alt_price
#: model_terms:ir.ui.view,arch_db:website_sale_b2x_alt_price.alt_price
msgid "without taxes"
msgstr "tasse escluse"
Loading
Loading