跳至內容
選單
此問題已被標幟
1 回覆
7699 瀏覽次數

In Odoo V13 enterprise.


I have an invoice and I want to find the relevant payment record but the invoices ID is in the 'reconciled_invoice_ids' many2many field.


If I do env['account.payment'].search([('reconciled_invoice_ids','=',invoice.id)]) it returns quite a few payments without the relevant ID in the reconciled field.


If I try .search([(invoice.id,'in','reconciled_invoice_ids')]) it gives me an invalid leaf error.


I am not really sure what the correct way to do this is.

頭像
捨棄
最佳答案

Jonah,

Did you tried for this 

 search ([('reconciled_invoice_ids', 'in', invoice.id)])


or 


search ([('reconciled_invoice_ids', 'in', invoice.ids)])

Regards,




Email:    odoo@aktivsoftware.com  

Skype: kalpeshmaheshwari

   

頭像
捨棄
相關帖文 回覆 瀏覽次數 活動
1
9月 23
2388
7
6月 20
6780
7
7月 18
20817
2
7月 17
3417
0
11月 22
80