Bỏ qua để đến Nội dung
Menu
Câu hỏi này đã bị gắn cờ
1 Trả lời
5412 Lượt xem

Hi All,

Brand new here. Doing some work for a client running Odoo.

Essentially we will be creating Sales Orders in a Rails Application which then need to be sent across to Odoo.

Is there any documentation anywhere on how to achieve this? I have search for hours and can find no samples.

I think I understand the model concept. Eg. sales.order is a model with related lines and that create is a operation but what should we send through that operation?

Is there any proper docs describing how to create sales orders. Eg. how to use it, definition of all parameter we need to send what's is the response format etc.

Currently I'm able to connect to the Client's Odoo system through api and can execute operations like(read, search) through api etc. But do not know how to create an Order and the associated lines.

I'm sure this can't be too difficult. Any guidance will be greatly appreciated.

Thanks in advance Odooers !!!

Ảnh đại diện
Huỷ bỏ
Câu trả lời hay nhất

Hi,

Please refer this Odoo documentation about the web service API,  it is explained in it with sample codes

https://www.odoo.com/documentation/10.0/api_integration.html

To create a record in a model,

id = models.execute_kw(db, uid, password, 'res.partner', 'create', [{
    name: "New Partner",
}])

Thanks

Ảnh đại diện
Huỷ bỏ
Bài viết liên quan Trả lời Lượt xem Hoạt động
0
thg 2 24
1723
2
thg 12 23
41135
3
thg 8 25
3390
3
thg 10 24
8536
2
thg 3 24
5896