Overslaan naar inhoud
Menu
Je moet geregistreerd zijn om te kunnen communiceren met de community.
Deze vraag is gerapporteerd
1 Beantwoorden
3608 Weergaven

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
Annuleer
Beste antwoord

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
Annuleer
Gerelateerde posts Antwoorden Weergaven Activiteit
2
okt. 21
3686
1
feb. 16
5556
2
mrt. 15
4446
1
mrt. 15
10356
0
jul. 25
318