Skip to Content
Menu
This question has been flagged
1 Atsakyti
8162 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
4809
0
geg. 24
1974
1
bal. 24
1993
0
rugp. 21
9027
0
liep. 17
2814