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.

0

Javascript warning message

By
Marek Jan-Alexander
on 3/29/15, 1:27 PM 840 views

Hi community,

is there a (simple) way to raise a javacript warning message on onchange event.? Basically the same which is already raised when a mandatory field is not filled. Is there any existing module where this function works?

Thanks for help!

0
Marek Jan-Alexander
On 3/31/15, 1:27 PM

Thanks, Jérémy, for your answer but this is actually not what i meant. I would like to raise a message in the right corner, precisely in the same way as the message that popups when mandatory field is not filled. 

0

Jérémy Kersten (jke)

--Jérémy Kersten (jke)--
2993
| 3 2 5
Jodoigne, Belgium
--Jérémy Kersten (jke)--

Jérémy is a member of the core R&D team since september 2013. He developed several projects for OpenERP version 8 including the eCommerce, the Google Calendar synchronization and the new product variants/configurator. Now, he manages Odoo website and themes for saas.

Jérémy Kersten (jke)
On 3/29/15, 2:46 PM

In a on change, you can raise a warning or/and values...

        return {
'warning': {
'title': _('Title'),
'message': _('Your message'),
},
'value': values,
}


From doc: 

Be careful not to use @api.one in that case as it will mangle the dictionary (put it in a list, which is not supported by the web client).

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

2 follower(s)

Stats

Asked: 3/29/15, 1:27 PM
Seen: 840 times
Last updated: 3/31/15, 1:27 PM