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

What is the perfect way to show only some rows in a one2many filed

Avatar
Zrušit
Nejlepší odpověď

HI Jacky,


you can use domain to filter the one2many.
Like 

expense_ids = fields.One2many('hr.expense', 'sale_order_id', string='Expenses', domain=[('state', '=', 'done')], readonly=True, copy=False)

Refer this question, you get more ideas:
https://www.odoo.com/forum/help-1/question/how-to-write-this-domain-for-a-one2many-field-on-a-view-114226

regards, Nikhil
Avatar
Zrušit
Related Posts Odpovědi Zobrazení Aktivita
1
led 25
1829
2
zář 22
9573
2
dub 22
4623
0
čvc 21
7271
1
bře 21
5015