Odoo Help

Welcome!

This community is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.

1

What's a good way to import data through the Odoo API?

By
Kasper Souren
on 7/2/14, 11:47 AM 2,928 views

I want to import XML data related to orders into an Odoo setup. What's a good approach for this? Which addon dependencies do I need?

What does a method look like that reads the xml data from my source and converts it into orders into odoo? Is there documentation about this? I want to see the most minimal Odoo addon that adds some data to an installation.

What do you know about developing openerp modules themselves? Because if you know that, you are half-way through. Look into xml-parsers in python and use the ORM's "create" method on the records to turn them into sale orders. For scheduler examples (like Serpent is talking about) take a look at the current schedulers, for example the "Run mrp scheduler" from the MRP module.

Ludo - Neobis
on 7/4/14, 7:38 AM
3

Serpent Consulting Services Pvt. Ltd.

--Serpent Consulting Services Pvt. Ltd.--
4341
| 6 6 8
Gandhinagar, India
--Serpent Consulting Services Pvt. Ltd.--

Serpent Consulting Services Pvt. Ltd. Your Odoo/OpenERP Solution, just an email away!

Serpent Consulting Services Pvt. Ltd.
On 7/2/14, 12:23 PM

Kasper,

You should make a method which reads the xml data from your source and converts them into orders into odoo.

This method should be mentioned into the scheduler which will be configured to run every hour. (menu is Settings/Technical/Scheduler/Scheduled Actions)

Thanks.

Cool. What does such a method look like?

Kasper Souren
on 7/4/14, 7:22 AM

You will write a method which will import orders to odoo. That name of method should be defined in the scheduler.

Serpent Consulting Services Pvt. Ltd.
on 7/4/14, 8:00 AM
0
Kasper Souren
On 7/2/14, 3:38 PM

http://stackoverflow.com/questions/11493578/how-to-write-a-python-script-that-uses-the-openerp-orm-to-directly-upload-to-pos/11499665#11499665 looks promising

Your Answer

Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!

About This Community

This community is for professionals and enthusiasts of our products and services. Read Guidelines

Question tools

4 follower(s)

Stats

Asked: 7/2/14, 11:47 AM
Seen: 2928 times
Last updated: 3/16/15, 8:10 AM