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

I want to extract name from partner_ids i.e. a many2many field, so that i can use it with the attachment prefix for the 'partner ledger report'. Please help if anyone can.

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

partner_ids is a list, so you can access the first value as such partner_ids[0].name

Ảnh đại diện
Huỷ bỏ
Tác giả

You are right, but the problem is I already tried this way and its not working. I have to use 'object.field_name+.pdf' kind of expression to save the report as attachment. When I try like this the report doesn't get printed and i get this error: "TypeError: coercing to Unicode: need string or buffer, tuple found"

Bài viết liên quan Trả lời Lượt xem Hoạt động
0
thg 3 15
5329
0
thg 3 15
4508
1
thg 4 17
329
3
thg 8 16
9425
2
thg 3 15
9424