Odoo Help


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.


How do I remove a cell from a single row table?

on 5/14/13, 11:51 AM 2,001 views

What is the correct way to remove a single cell from a 4 cellesingle row table based on a condition? (I want to remove the third cell).

I have the following formula that is supposed to print "Great Client" if the word "Great" is located within the client name:

(so.partner_id.name.find('Great') > 0) and "Great Client" or removeParentNode('td')

It works fine when the condition is met, but I get an error message when it isn't, i.e. when it hits the removeParentNode('td'):

(<type 'exceptions.AssertionError'>, AssertionError(), <traceback object at 0x7fdae4b7e248>)

How is it possible to remove a single cell from a single row table?

you need to post all the code in the module to get a good answer.

AJ Schrafel Paper Corp
on 5/14/13, 12:31 PM

The trml2pdf.py file is over 1000 lines long, do you really want me to post it? Please understand that my formula rests within a dynamic report developed in OpenOffice writer.

on 5/15/13, 7:17 PM

Andreas Maertens

--Andreas Maertens--
| 5 5 7
Finsterwalde, Germany
--Andreas Maertens--

I develop odoo8.0 modules

Andreas Maertens
On 5/14/13, 12:34 PM

Maybe you declared the with of every row in the <blocktable> tag? Than the node needs to be there.

Why don't let it free if condition doesn't met?

(so.partner_id.name.find('Great') > 0) and "Great Client"

From OpenOffice Writer I can't control where the width is stored. The reason why I don't leave it empty is that I simply want to remove the third cell out of 4 and therefore reduce the overall width of the table.

on 5/15/13, 7:15 PM

Oh sorry, my answer doesn't apply to Reportcreation with OpenOffice. I use a texteditor to alter the .rml files by hand.

Andreas Maertens
on 5/16/13, 3:54 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)


Asked: 5/14/13, 11:51 AM
Seen: 2001 times
Last updated: 3/16/15, 8:10 AM