İçereği Atla
Menü
Bu soru işaretlendi
1 Cevapla
3803 Görünümler

I have a method in a model with this signature:

@api.model
def do_stuff(self, arg1):
...


The method expects a singleton therefore I must pass an ID when calling it. How can I pass the object ID when in the web service calls?


Avatar
Vazgeç
En İyi Yanıt

while calling these method decorated with @api.model just pass the blank list like 

models.execute_kw(dbname, uid, password,    'my.model', 'do_stuff' ,[])
Avatar
Vazgeç
İlgili Gönderiler Cevaplar Görünümler Aktivite
2
Eki 21
3923
1
Şub 16
5797
2
Mar 15
4602
1
Mar 15
10667
0
Tem 25
497