Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

0

Extract name from partner_ids?

By
evon_dun
on 10/8/13, 8:21 AM 1,053 views

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.

0

IBS

--IBS--
1302
| 4 5 8
Tétouan, Morocco
--IBS--

For more informations about IBS, please visit our website at www.ibs-na.com.

For a specific questions, collaboration or help, please send us an email to support@ibs-na.com

IBS
On 10/8/13, 2:08 PM

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

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"

evon_dun
on 10/9/13, 2:39 AM

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

0 follower(s)

Stats

Asked: 10/8/13, 8:21 AM
Seen: 1053 times
Last updated: 3/16/15, 8:10 AM