Skip to Content
Menu
This question has been flagged
2 Replies
4809 Zobrazenia


import odoorpc
odoo.env['account.invoice'].search(['partner_id', '=', 1])

Raises this exception;

odoorpc.error.RPCError: Invalid leaf partner_id

Expected:

returns a resultset of all invoices for that account

Avatar
Zrušiť
Best Answer

Search take as param a list of tuple ! So search([('partner_id','=', 1)])

Avatar
Zrušiť
Related Posts Replies Zobrazenia Aktivita
1
feb 25
1497
3
júl 20
13037
0
sep 19
98
1
júl 17
4343
4
aug 16
8521