تخطي للذهاب إلى المحتوى
القائمة
لقد تم الإبلاغ عن هذا السؤال
1 الرد
3703 أدوات العرض

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.


الصورة الرمزية
إهمال
أفضل إجابة

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'

الصورة الرمزية
إهمال
الكاتب

Thanks!

المنشورات ذات الصلة الردود أدوات العرض النشاط
1
أكتوبر 23
2711
2
أبريل 16
15461
3
يونيو 25
1508
2
مارس 25
2006
3
يوليو 24
2666