Odoo Help


[Widget Javascript]: How to make a query on a model odoo?

Vale Trood
on 9/9/16, 11:45 AM 1,121 views

Hello everybody!!!

Can anyone explain to me why didi this query not working please.

I have created a new widget and i need to create a wuery on a model in my odoo session. I have tried this but it doesnt work and i wouldnt understand the source of the problem.

Need your help please.

     new Model('hr.test').query(['name', 'code'])

.filter([['code', '=', 11399]])


.all().then(function (ret) {


var name = ret['name']


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/9/16, 11:45 AM
Seen: 1121 times
Last updated: 9/9/16, 11:45 AM