Hi.
I have a stand alone python code that interacts with a few variables, im wondering if there is a way to conect to OpenERP and extract those variables from sale.order.
Is it possible?, how can i do it?
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
Hi.
I have a stand alone python code that interacts with a few variables, im wondering if there is a way to conect to OpenERP and extract those variables from sale.order.
Is it possible?, how can i do it?
You can use openerp client lib (search for it on Github), and try this to start with:
import openerplib
connection = openerplib.get_connection(hostname="localhost", database=dbname,
login=username, password=pwd)
sale_model = connection.get_model("sale.order")
ids = sale_model.search([])
for id in ids:
so = sale_model.read(id, ["name"])
print so
Luo tili jo tänään nauttiaksesi yksinoikeusominaisuuksista ja osallistuaksesi mahtavaan yhteisöömme!
RekisteröidyAiheeseen liittyviä artikkeleita | Vastaukset | Näkymät | Toimenpide | |
---|---|---|---|---|
|
1
maalisk. 15
|
4285 | ||
|
0
maalisk. 15
|
4003 | ||
|
2
maalisk. 15
|
9081 | ||
Database for my module not created
Ratkaistu
|
|
4
huhtik. 24
|
2464 | |
|
1
toukok. 22
|
4988 |
Yes, it is possible. You can refer web services in OpenERP to do it. Link: https://doc.openerp.com/6.0/developer/6_22_XML-RPC_web_services/