[FIX] web: RTL on list view
- Set the user language to a RTL language, e.g. Arabic - Open a list view containing float or monetary fields, e.g. the invoice list view The numbers are left aligned while the corresponding columns headers are right aligned, making the list view confusing. The header alignment is hardcoded at rendering rather than in the SCSS. Therefore, `rtlcss` doesn't affect it. Instead of hardcoding the alignment, we use a proper CSS class so it is adapted by `rtlcss`. opw-2044019 closes odoo/odoo#35414 Signed-off-by: Nicolas Martinelli (nim) <nim@odoo.com>
This commit is contained in:
@@ -560,7 +560,7 @@ var ListRenderer = BasicRenderer.extend({
|
||||
}
|
||||
|
||||
if (field.type === 'float' || field.type === 'integer' || field.type === 'monetary') {
|
||||
$th.css({ textAlign: 'right' });
|
||||
$th.addClass('o_list_number_th');
|
||||
}
|
||||
|
||||
if (config.debug) {
|
||||
|
||||
@@ -31,6 +31,9 @@
|
||||
&:not(.o_column_sortable):hover {
|
||||
cursor: default;
|
||||
}
|
||||
&.o_list_number_th {
|
||||
text-align: right;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user