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

hello,


In stock module, I have 'inventory control' -> 'products'; when switched to list view I can see list as on pisture attached. Problem I have is that I can sort the list using for example 'product type' column (marked green), but cannot sort using 'quantity on hand' nor 'forecasted quantity'. View name used for the list is 'product.template.product.tree'; column 'quantity on hand' and 'forecasted quantity' are inherited from other, 'product.template.stock.tree.inherit'.

How to make fields marked in red on picture, labeled as:

<field name="qty_available"/>

<field name="virtual_available"/>

to be sortable?


regards

Tomasz

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

That fields are compute fields. By default, they are not stored at database, so you cant sort products by that fields.

You can set them store="True" and thats make it possible to sort on qty on hand of forecast

الصورة الرمزية
إهمال

Indeed, and yet, the more computed fields are in tree view, the more it takes to be fully charged. You should use them wisely.

الكاتب أفضل إجابة

 


..and picture attached.
الصورة الرمزية
إهمال
المنشورات ذات الصلة الردود أدوات العرض النشاط
Sticky Field تم الحل
1
نوفمبر 19
3504
0
يناير 25
1
0
يوليو 24
975
3
مايو 16
5519
2
ديسمبر 22
7302