Can someone help me to print only a part of a field in a PDF? Example for an Invoice, tax line: "20% VAT - EU Sales" should turn into "20% VAT". Guess it should be possible by using some field attribute, like [[ format(t.name) [:7] ]] in Openerp 5 & 6 RML, but I don't know how to do it in Odoo 8.
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project management
- MRP
This question has been flagged
Try this:
<span t-esc="t.name[:7]"/>
Accepted this for you. Great answer!
It does not work in my invoice report. I want to short the Units showed under Quantity in the invoice body (in Spanish and German too long) .
<td class="text-right; text-nowrap " >
<span t-field="line.quantity"/>
<span t-field="line.product_uom_id" groups="uom.group_uom" >
</td>
This is the code. I tried in many different ways but nothing short the UoM from "Unidades" (Units) to "Unid" or better "Unid."
Can you help me?
The only one I did not try....Thanks, works fine!