Odoo Help


module num2words(module hr_holidays)

on 9/8/16, 5:52 AM 326 views


this is my code :


from num2words import num2words

number_text=fields.Char(string='Nombre de jour')

def calculatenumber(number_of_days_temp):

number_text = num2words(number_of_days_temp, lang='fr')

return {'value': {'number_text': number_text}}


<xpath expr="//field[@name='interim']" position="after">

<field name="number_of_days_temp" nolabel="1" on_change="calculatenumber(number_of_days_temp)"/>


<field name="number_of_days_temp" position="after">

<field name="number_text"/>


,i got this error i dont know how to solve it

TypeError: calculatenumber() takes exactly 1 argument (5 given)

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 platform 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.


Odoo Training Center

Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.

Test it now

Question tools

1 follower(s)


Asked: 9/8/16, 5:52 AM
Seen: 326 times
Last updated: 9/8/16, 3:49 PM