Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
7758 Lượt xem

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.

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

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

   

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
1
thg 9 23
2417
7
thg 6 20
6841
7
thg 7 18
20898
2
thg 7 17
3450
0
thg 11 22
80