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

odoo 8 magento_integration: import sale orders error

By
Tankgirl
on 11/14/14, 6:13 AM 1,194 views

I have modified the Magento_integration module so it could be added to odoo 8.


To do this I have changed all sale.shop instances in to stock.warehouse and sale_shop to stock_warehouse
I have also changed sale.py on line 359 to:            
'pricelist_id': partner.property_product_pricelist.id,

Now I'm getting the following error while trying to import sale order (products import works):

  File "/opt/odoo/addons/magento_integration/partner.py", line 225, in find_or_create_address_as_partner_using_magento_data
    for address in parent.child_ids + [parent]:
  File "/opt/odoo/openerp/models.py", line 5352, in __add__
    raise except_orm("ValueError", "Mixing apples and oranges: %s + %s" % (self, other))
except_orm: ('ValueError', 'Mixing apples and oranges: res.partner() + [res.partner(6,)]')

The piece of code where this error comes from is:

  for address in parent.child_ids + [parent]:
            if self.match_address_with_magento_data(
                cursor, user, address, address_data
            ):
                break
        else:
            address = self.create_address_as_partner_using_magento_data(
                cursor, user, address_data, parent, context
            )

        return address



I guess this has to do with getting the right field, can anyone help me?

Thanks in advance

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

1 follower(s)

Stats

Asked: 11/14/14, 6:13 AM
Seen: 1194 times
Last updated: 6/15/15, 6:58 AM