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.

1

as making a sum total of some fields of my object with mako?

By
alfonso olavarria
on 5/15/13, 1:20 PM 962 views

Hi, I have a smatoria of values ​​that I have. % for order in objects: $ {amount_total}-here are the values ​​I want to add at every turn to give me a total

but so I can not because in the mako that I have when I embed this.

<% variable_acumulada = 0 %>

% for order in objects: variable_acumulada + = orden.amount_total % endfor

I print to pdf variable_acumuladora + = orden.amount_total

and if I put it like that.

<% variable_acumulada = 0 %> % for order in objects: variable_acumulada + = $ {orden.amount_total} % endfor

prints for each turn me this.

lap 1 variable_acumuladora + = 86.5

turn 2 variable_acumuladora + = 1.05

Thanks for responding. alfonsojn15@gmail.com

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: 5/15/13, 1:20 PM
Seen: 962 times
Last updated: 3/16/15, 8:10 AM