Skip to Content
Menu
This question has been flagged
1 Atsakyti
8352 Rodiniai

Hi,

I want to fetch the state of the active_id using java script. can anyone help how to achieve this?

Portretas
Atmesti
Best Answer

        fetch: function(model, fields, domain, ctx){
            return new instance.web.Model(model).query(fields).filter(domain).context(ctx).all()
        },

Make use of the above fetch function you can fetch data.

Example:

self.fetch('res.users',['name','company_id'],[['id','=',this.session.uid]]).then(function(users){

console.log("This is the User",users);

});

Portretas
Atmesti
Related Posts Replies Rodiniai Veikla
1
lapkr. 24
5088
0
geg. 24
2203
1
bal. 24
2149
0
rugp. 21
9167
0
liep. 17
2976