Skip to content
Snippets Groups Projects
user avatar
Ivan Yelizariev authored
Odoo 16 has new feature *Comparison Price*. It allows to show striked price
after the main price. E.g. `$555 -$666-`.

It doesn't work well however on using RTL languages because of *Unicode
Bidirectional Algorithm*. For example, in Egyptian localizations it shows some
mess of striked and not striked characters: `LE -LE-666- 555`. The correct
display should be `-LE-666- LE 555`. (Examples are even more complicated with
symbol E£ that is currently used by default for EGP).

As a solution, use `<bdi>` element to isolate stiked value. Also we have to use attribute
`dir="inherit"` to avoid changing direction for currencies that use LTR
characters, otherwise the result would be `-666-LE- LE 555`.

STEPS:

- Go to settings > website: Activate *Comparison Price*
- Go to Sales > Pricelist: add extra pricelists with EGP currency and mark it
as **Selectable**
- Go to Setting > Languages: activate the Arabic language and add it to the website.
- Go to the product form: add **Compare to Price**
- Go to the website > products, select pricelist EGP

opw-3188129
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdi



closes odoo/odoo#113261

Signed-off-by: default avatarAntoine Vandevenne (anv) <anv@odoo.com>
af25b39f
History

Build Status Tech Doc Help Nightly Builds

Odoo

Odoo is a suite of web based open source business apps.

The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...

Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.

Getting started with Odoo

For a standard installation please follow the Setup instructions from the documentation.

To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials