Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
2515 Weergaven

I would like to sort pricelists by the product code and description ("applicable on" field as shown below), instead of by other fields like MOQ and start/end dates. How can I do this?


I tried to do this within studio, but the "applicable on" field was not available to choose from for sorting ("applied on" is a different, normally invisible, field):


Avatar
Annuleer
Beste antwoord

Hello Paul Phillips,

You can try '_order' attribute in your model to sort the records as shown below.

_inherit = "product.pricelist.item"
_order = "applicable_on,field_2 asc, field_3 desc"

Please refer below link it may help you to configured properly.
link: https://www.odoo.com/documentation/15.0/developer/howtos/rdtraining/12_sprinkles.html?highlight=_order

Thanks & Regards,
Email: odoo@aktivsoftware.com
Skype: kalpeshmaheshwari

Avatar
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
1
jun. 25
419
1
jun. 22
1939
1
nov. 21
1517
0
apr. 21
1846
1
okt. 24
1954