Přejít na obsah
Menu
You need to be registered to interact with the community.
This question has been flagged
2 Odpovědi
2718 Zobrazení

Hi,

I need to know how to get only stockable products for a Many2one field.

Avatar
Zrušit
Nejlepší odpověď

hello

apply the domain on the M2O field

<field name="your_fieldname" domain="[('type', '=', 'product')]"/>

Avatar
Zrušit
Nejlepší odpověď

Hello Dishan,

pass domain for many2one field.

domain = "[('type','=','product')]"  if you pass this domain on your xml it will filter only stockable products.

if you want only on hand qty available products then add this domain , domain = "[('qty_available','&gt;',0)]"


Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
3
říj 23
19144
5
říj 20
3835
2
čvn 20
6482
5
dub 25
16103
1
čvc 23
4263