Import VM Order from guest problem

  • Posts: 189
  • Thank you received: 11
  • Hikashop Business
8 years 4 months ago #244299

-- HikaShop version -- : 2.6.3
-- Joomla version -- : 3.5.1
-- PHP version -- : 7.0.9
-- Browser(s) name and version -- : FF

I tried to import from Virtuemart. All import parts work like the should exept for the order import. I noticed tha my client disabled User registration so all checkouts are guest checkouts. When I do an import no order are getting imported except for the a couple of old test orders in which a test user created an account up front.

When I look in the database table: #_virtuemart_orders the virtuemart_user_id and created_by table are set as 0. When I change this 0 value to a existing user account ID this order gets imported.

I also noticed that the billing and shipping address are not being imported and are left blank.

I hope you guys can fix this!

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
8 years 4 months ago #244344

Hi,

Try changing the line:
'INNER JOIN `#__hikashop_user` AS hkusr ON vmo.virtuemart_user_id = hkusr.user_cms_id '.
to:
'LEFT JOIN `#__hikashop_user` AS hkusr ON vmo.virtuemart_user_id = hkusr.user_cms_id '.
in the file administrator/components/com_hikashop/helpers/import/vm2.php
and try again. It should allow the import of orders, even without users attached to them.

Regarding the addresses, I remember we fixed some issues with it when there was no country or state in the addresses, which lead to the addresses not being imported. That way in march. But since you have the latest version, you already have that fix, and thus it mus tbe something else.
Could you provide more information on the addresses ? How are they in the database ?

Please Log in or Create an account to join the conversation.

  • Posts: 189
  • Thank you received: 11
  • Hikashop Business
8 years 4 months ago #245010

Hi Nicolas,

Thanks for your answer!
The import worked, but... The only problem is that from the more than 600 order only a hand full shipping addresses are getting imported. I have no clue how to debug this. Do you have an idea ho to fix this? The site is on my local webserver so unfortunately I can't give you access.

Thanks in advance!

Please Log in or Create an account to join the conversation.

  • Posts: 82863
  • Thank you received: 13372
  • MODERATOR
8 years 4 months ago #245019

Hi,

Well, it's going to be complex. But if some address import and not others, it's a good start.
Please check the table virtuemart_order_userinfos in your database with PHPMyAdmin. There, check the differences between the addresses that imported and the ones that didn't.
Knowing the differences will greatly help understand what needs to be done.

Please Log in or Create an account to join the conversation.

Time to create page: 0.058 seconds
Powered by Kunena Forum