コンテンツへスキップ
メニュー
この質問にフラグが付けられました
2 返信
4764 ビュー

I am trying to update the sales order within Odoo 13 via the API


 so_id = models.execute_kw(db, uid, password, 'sales order', 'write'[{

          'name': 'order name"

           #update state 

        }])

This however does not work. Per the documentation https://www.odoo.com/documentation/13.0/webservices/odoo.html we should user the write method to update records, and I have done so but still can't figure out the issue. When I attempt to write to Odoo it just returns a 500 error.

アバター
破棄
最善の回答

The documentation gives an example with the ID of the record you want to change, so I would start by fixing that:

models.execute_kw(db, uid, password, 'res.partner', 'write', [[id], {
    'name': "Newer partner"
}])
アバター
破棄
著作者

I did end up figuring it but thank you. I wasn't marking the ID correctly on my end.

関連投稿 返信 ビュー 活動
1
7月 25
2575
0
5月 23
2318
3
3月 25
24026
1
11月 22
2262
1
5月 22
5748