correct syntax for odt template?

correct syntax for odt template?

Postby jluitz » Mon Jan 13, 2014 4:43 pm

Dear all,

when using template-mime type "generic" the following code works like charm:
Code: Select all
{% for o in objects %}\
${o.product_qty}   [${o.code}]   ${}

{% with item = search('',[('bom_id','=',]) %}\
{% for i in item %}\
${i.product_qty}   [${i.product_id.default_code}]   ${i.product_id.name_template}
{% end %}\
{% end %}\
{% end %}

Trying to do the same in ODT or ODS hopelessly fails returning
Code: Select all
TypeError: coercing to Unicode: need string or buffer, tuple found

The problem seems to lie in the WITH statement.

What would be the correct syntax for the WITH statement in ODS/ODT to achieve the same result?

Thanks for your help
Posts: 2
Joined: Sun Feb 10, 2013 11:10 pm

Return to Aeroo Reports & Reporting Engine

Copyright © 2001 Alistek Ltd., ALL RIGHTS RESERVED