Odoo Help


on_change event don't work with date field

on 11/14/13, 11:57 AM 1,062 views


I want to create an on change event when writing on a date field: when i put 01 it should write automatically the month and the year (01.11.2013). I did that with other type of field but it doesn't work with date field, it just put the value when i save the record.

Any one have an idea about that and can help me?


Could you please post your code and where are you trying to add this functionality?

GH Mediacloud, Grover Menacho
on 11/14/13, 12:14 PM

hello, here is my function: def onchange_date(...,date,...): return {'value':{'field_date':date}} what i can't understand is that when i write 01 and i make a print of the 'field_date' i have 01.11.2013 so 'field_date' contain the good result but it's not showed untill i save the record

on 11/16/13, 7:36 AM

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

0 follower(s)


Asked: 11/14/13, 11:57 AM
Seen: 1062 times
Last updated: 3/16/15, 8:10 AM