Migrating from Opencart

  • Posts: 256
  • Thank you received: 21
1 month 1 week ago #363824

I am about to start a new project migrating a site from Opencart. In the documents it says "The data from OpenCart, RedShop and MijoShop can also be imported automatically into HikaShop. You'll find one selection for each shopping cart system and it will be active only if the shopping cart tables are detected in the database."
Does that mean I have to install Joomla on the existing Opencart database for this function to work?

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

  • Posts: 82862
  • Thank you received: 13370
  • MODERATOR
1 month 1 week ago #363826

Hi,

Not necessarily. However, the tables of OpenCart need to be on the same database server.
So, you could use PHPMyAdmin to export the tables of OpenCart and import them in the same database where you have your Joomla website with HikaShop in it.

The following user(s) said Thank You: rodfarrell

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

  • Posts: 256
  • Thank you received: 21
1 month 1 day ago #363998

Hi Nicholas,
I just attempted the import and get this error:
Attempt to assign property "main_currency" on null

I have tried with the setting "Do you want to import your Opencart currencies rates ?" set to both Yes and No and get the same result. This is opencart version 2.1.0.2

Is this a Hikashop setting or an Opencart setting that I need to fix?

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

  • Posts: 4747
  • Thank you received: 644
  • MODERATOR
1 month 1 day ago #364004

Hello,

In this kind of case, the method is to have more information around this error.
Therefore, you must activate Joomla debug mode, and at the maximum level.



Then reproduce your issue, your error message will then be enriched with more information, so provided a screenshot so that we have more clues.
Regards

Last edit: 1 month 1 day ago by Philip.

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

  • Posts: 256
  • Thank you received: 21
1 month 13 hours ago #364019

Thanks Philip,
I have set error reporting to maximum and debug on. I have also set logging to "almost everything". The error logs remain empty and the screen shot is here.

Attachments:

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

  • Posts: 4747
  • Thank you received: 644
  • MODERATOR
4 weeks 2 days ago #364031

Hello,

Unfortunately this help us... Sorry for that.
And so, we will need but can you provide your csv file (our your database file) to better understand the situation.
Use our Contact us form to provide this, and don't forget to add an Url link to this topic.
Regards

Last edit: 1 month 1 hour ago by Philip.

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

  • Posts: 256
  • Thank you received: 21
3 weeks 3 days ago #364146

Thanks Philip,
I just took the code snippet in openc.php (around line 261 to 271) and asked Chatgpt what it did. I then took the output array of the $result that the code was trying to process and gave it to chatgpt as well as the error and asked what was wrong.

ChatGPT responded
"The error message "Attempt to assign property 'main_currency' on null" suggests that $this->options is not initialized before this code is executed. If $this->options is null, attempting to assign $this->options->$nk will cause this error."
and gave me this code to add at line 259

if (!is_object($this->options)) {
$this->options = new stdClass();
}

This has resolved the problem. Holy crap, we are all going to be out of work soon!!!

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

  • Posts: 82862
  • Thank you received: 13370
  • MODERATOR
3 weeks 3 days ago #364148

Hi,

Thanks for your feedback.
I've made a similar patch on our end and included it in the install package available on our website.

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

  • Posts: 256
  • Thank you received: 21
3 weeks 2 days ago #364158

Glad it was resolved.

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

Time to create page: 0.076 seconds
Powered by Kunena Forum