Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
5 changes: 3 additions & 2 deletions l10n_ar_website_sale_ux/README.rst
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,8 @@
l10n_ar Website Sale UX
=======================

#. This module adds a "(+ tax)" legend next to the product price on the ecommerce product and product_item views.
#. This module adds a "(+ tax)" legend next to the product price on the ecommerce product and product_item views for b2b customers
#. This module also hides the tax discrimination line on the cart checkout page for b2c customers.

Installation
============
Expand All @@ -28,7 +29,7 @@ Configuration

To configure this module, you need to:

#. No configuration needed.
#. Go to Users > Groups and add a customer to either b2b or b2c groups depending on wheter you want them to see tax discrimination or not on ecommerce.

Usage
=====
Expand Down
3 changes: 2 additions & 1 deletion l10n_ar_website_sale_ux/__manifest__.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@
{
'name': 'l10n_ar Website Sale UX',
'category': 'base.module_category_knowledge_management',
'version': '13.0.1.0.0',
'version': '13.0.1.1.0',
'author': 'ADHOC SA',
'website': 'www.adhoc.com.ar',
'license': 'AGPL-3',
Expand All @@ -30,6 +30,7 @@
],
'data': [
'views/l10n_ar_website_sale_ux.xml',
'views/l10n_ar_website_sale_hide_taxes.xml'
],
'installable': True,
}
15 changes: 15 additions & 0 deletions l10n_ar_website_sale_ux/views/l10n_ar_website_sale_hide_taxes.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?xml version="1.0" encoding="utf-8"?>
<odoo>
<template id="website_sale_hide_taxes" name="Hide Taxes" inherit_id="website_sale.total">
<xpath expr="//tr[@id='order_total_untaxed']//span" position="attributes">
<attribute name="groups">account.group_show_line_subtotals_tax_excluded</attribute>
<attribute name="t-field">website_sale_order.amount_untaxed</attribute>
</xpath>
<xpath expr="//tr[@id='order_total_untaxed']//span" position="after">
<span t-field="website_sale_order.amount_total" groups="account.group_show_line_subtotals_tax_included" class="monetary_field" style="white-space: nowrap;" t-options="{'widget': 'monetary', 'display_currency': website_sale_order.currency_id}"/>
</xpath>
<tr id='order_total_taxes' position="attributes">
<attribute name="groups">account.group_show_line_subtotals_tax_excluded</attribute>
</tr>
</template>
</odoo>