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 to transfer a value from order to invoice

on 5/19/16, 3:28 AM 252 views


in pos_order, I inherited "action_invoice" to send a value I created for a reduction ticket (here is the code : http://pastebin.com/JxjXgD5y).

The action is done when you click on the button in the red circle here : http://i.imgur.com/o1bT6Ev.png

The problem I have is that I don't know how and where I can get this value in account_invoice.

Thank you in advance for your help !

ayman mohammed adam
On 5/19/16, 7:23 AM

Dear Matthieu,

if i understand you correctly , when you want to send value directly to total that is impossible because the total field in invoice is functional field , it's function return the total after sum all the subtotal on the invoice lines. if you want to send value to invoice you can do by any of two ways:

1- send it in invoice lines.

2. create new field on account.invoice and send the value directly,. in this case you must modify the total functional field.

Yes, thank you. I think in my case, the second option is the best one. But there is no "_columns" so I think we need to create it in "compute_amount(self)". Am i right ? Once again, thank you so much !

on 5/19/16, 8:15 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

1 follower(s)


Asked: 5/19/16, 3:28 AM
Seen: 252 times
Last updated: 5/19/16, 7:23 AM