Se rendre au contenu
Menu
Cette question a été signalée
1 Répondre
3713 Vues

Hi

How can I sort attribute values shown on the website. For example, I am using an attribute width with values 347, 397, and 447 but they are shown in the order 397, 447, 347 (in order I created these products). I am using Odoo 14.


Avatar
Ignorer
Meilleure réponse

You will need to create a custom Module. See the documentation for how to do that.

from odoo import models

class ProductAttributevalue(models.Model):
    _inherit = 'product.attribute.value'
    _order = 'name asc'

Avatar
Ignorer
Auteur

Thanks!

Publications associées Réponses Vues Activité
1
oct. 23
2729
2
avr. 16
15488
3
juin 25
1578
2
mars 25
2027
3
juil. 24
2683