Skip to Content
Menu
Musisz się zarejestrować, aby móc wchodzić w interakcje z tą społecznością.
To pytanie dostało ostrzeżenie
1 Odpowiedz
1953 Widoki

Cómo deshabilitar la ordenación por en una vista de árbol 'One2many'

Awatar
Odrzuć
Najlepsza odpowiedź

Hi,

Here you can use the '_order ' attribute of odoo which is used to sort the recordset in list view either in ascending or descending.

Go to the class definition python code of your co-model of the One2many field, there we can set the attributes _name, _description, _rec_name, etc. Like that, _order can also be given as

_order = "sequence"
If you want to sort in descending order, give

_order = "sequence desc"

Hope it helps

Awatar
Odrzuć
Powiązane posty Odpowiedzi Widoki Czynność
3
kwi 25
12070
1
wrz 21
3271
3
maj 16
9500
1
kwi 16
4580
1
sie 25
718