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.


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

Drees Far
on 9/9/16, 11:45 AM 182 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']


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