Post by Rainforest » Wed Dec 30, 2015 9:08 am

I've sucessfully upgraded my 1.5.6 store using the migration upload tool.

Things seem to be OK.

However, when I go to an order and try to VIEW it I get this error:

Fatal error: Class 'Controllerpayment' not found in /xxx/public_html/system/engine/loader.php on line 28

Line 28 is : $controller = new $class($this->registry);

(BTW If I click on the EDIT button, no issues.)

Any ideas?
Thank you!

Active Member

Posts

Joined
Fri Jan 28, 2011 3:50 am

Post by bxmas13 » Fri Jan 01, 2016 5:20 am

I was having the same issue today. In my situation the problem turned out that after the upgrade I failed to install and enable a Payment extension that was associated with the order.

The error is associated with the 'payment_code' field in the oc_order table.
Error is thrown by line 1240 in /admin/controller/sale/order.php

Code: Select all

$content = $this->load->controller('payment/' . $order_info['payment_code'] . '/order');

Newbie

Posts

Joined
Sat Nov 16, 2013 8:53 am

Post by soundzgood-nz » Sun Jan 03, 2016 1:30 pm

Change the payment_code in the orders table to the correct / updated payment_code of the replacement oc2 payment module. Example - payment_code 'dps_pxpay' in 1564 would need to be updated to 'paymentexpress' in 2101

Simon

User avatar
Active Member

Posts

Joined
Sat Oct 25, 2014 5:15 pm
Location - New Zealand

Post by HAO » Fri Jan 08, 2016 1:42 pm

I also have the same problem.

But my case is upgrading database manually from 1.5.6.4 to 2.1.0.1 version, For oc_user, oc_user_group, oc_setting data sheets, directly copied from the new 2.1.0.1, All functions are normal, but Orders that can not be displayed.

How can I deal with this problem?

My Error Code:

Code: Select all

Fatal error: Class 'Controllerpayment' not found in /xxx/public_html/system/storage/modification/system/engine/loader.php on line 28

HAO
Active Member

Posts

Joined
Fri Jun 03, 2011 2:52 pm

Post by bxmas13 » Sat Jan 09, 2016 2:29 am

Find out what payment system you are using and do what soundzgood-nz suggested in the previous post:

Change the payment_code in the orders table to the correct / updated payment_code of the replacement oc2 payment module. Example - payment_code 'dps_pxpay' in 1564 would need to be updated to 'paymentexpress' in 2101

Newbie

Posts

Joined
Sat Nov 16, 2013 8:53 am

Post by HAO » Sat Jan 09, 2016 11:49 am

I did not think would be related with the Payment Method, i do have to install our country-specific payment module, After the substitution, indeed can read, thank you for reminding!

HAO
Active Member

Posts

Joined
Fri Jun 03, 2011 2:52 pm

Post by bxmas13 » Sun Jan 10, 2016 2:21 am

You are very welcome!

Newbie

Posts

Joined
Sat Nov 16, 2013 8:53 am

Post by htwp » Thu Jan 21, 2016 3:15 am

The same happens to me also i get the same error but i don't use the mentioned type of payments. This is happening to the unfinished orders when i am trying to view them. What i have discovered is in database table order column payment_code when this column is empty i cant view the unfinished orders. If i type manually any payment method then i can view it. Any help will be great as i am struggling to find the problem more than 2 weeks day and night without answer.
Thank you in advance.

Active Member

Posts

Joined
Sun Oct 14, 2012 1:29 am

Post by Randem » Thu Jan 21, 2016 3:56 am

Hi Rainforest,

You say you upgraded with the migration upload tool (never heard of that one). A lot of your error will happen if you use the wrong one. Could you be a little more specific with at least a link to it. I suggest this one - http://www.randemsystems.com/support/op ... n-2-1-0-1/

Hi HAO,

The manual update has caused you some issues I believe. if you don't get it correct your will have problems with orders - Reference: http://www.randemsystems.com/support/op ... cart-v2-x/

Hi htwp,

You have not given enough information as to how you came to get these errors... Please give some history.

NEVER take serious; anyone who gives negative impact statements with no ABSOLUTE proof!
OpenCart Helpful Information * Upgrade 1.5 to 2.1 * Upgrade 2.1 to 2.2
"Why do people NEVER have enough time to do it right but ALWAYS enough time to do it over?"
DO NOT EVER GIVE SOMEONE YOU DON"T KNOW ADMIN ACCESS TO ANYTHING!
I am NOT affiliated with OpenCart


User avatar
Active Member

Posts

Joined
Sat Sep 27, 2014 9:17 am

Post by reececropley » Tue Apr 05, 2016 12:06 am

Is there anywhere that I can find what the new payment_code names are for the new site.

I have a site with over £1.2 million pounds worth of orders that I would like migrated to the new version.

I have done a database search but nothing is coming back.

Thanks in advance.

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by reececropley » Tue Apr 05, 2016 12:53 am

Hello, I realised the payment code is in the URL of the payment methods module page.

I believe I have updated all but one (i.e sagepay_server_v3 [1.5.6] to sagepay_server [2.1.0.1])

There is one that I cant find the equivalent of, its the openbay amazon payment code. On the old site its amazon.amazon [1.5.6] - does anyone know what it is for the v2.1.0.1?

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by bxmas13 » Tue Apr 05, 2016 2:36 am

These are what I found for 2.1.0.1 Openbay Amazon payment_codes

amazonus.amazonus - catalog\controller\openbay\amazonus.php
amazon.amazon - catalog\controller\openbay\amazon.php
amazon_login_pay - catalog\controller\payment\amazon_login_pay.php

Hope that helps!

Newbie

Posts

Joined
Sat Nov 16, 2013 8:53 am

Post by reececropley » Tue Apr 05, 2016 9:10 pm

Cheers thats perfect.

The older version already uses amazon.amazon so I am now guessing its becuase OpenBay isn't fully integrated on the site. I will try and install it now and see if it all works and let you know.

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by reececropley » Tue Apr 05, 2016 10:40 pm

Could this same error be caused by the shipping_code as well? it appears the amazon order still throw the same issue.

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by bxmas13 » Wed Apr 06, 2016 2:00 am

I'm not sure, but I wouldn't think so. I have about 300 orders in my database that do not have a shipping_code and everything is working fine.

What is the error you are receiving now?
What payment modules do have enabled and active?

Newbie

Posts

Joined
Sat Nov 16, 2013 8:53 am

Post by reececropley » Wed Apr 06, 2016 11:22 pm

The Fatal Error I am getting on orders that used the OpenBay Amazon payment_code or don't have a value for payment_code is:

Fatal error: Class 'Controllerpayment' not found in /.../vqmod/vqcache/vq2-system_storage_modification_system_engine_loader.php on line 28

The payment methods and their payment code, I have installed are:

Paypal (pp_standard)
Sagepay (sagepay_server)
Cash on Delivery (cod)
Bank Transfer (bank_transfer)

OpenBay (amazon.amazon) - payment made on amazon

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by bxmas13 » Thu Apr 07, 2016 12:50 am

Any order that has a blank payment_code field is going to cause that error. You should replace the blank payment_code field with the code from an installed payment method.

As for the OpenBay orders causing that problem; it sounds like OpenBay is not installed correctly. Could you have installed the Amazon US version by accident?

Line 28 of the loader.php file is part of a loop that is looking at the payment_code field and trying to find the matching payment controller PHP file. On some order it's finding a payment_code that doesn't have a matching payment controller installed/enabled.

My suggestion would be to query your database and find any payment_code that DOES NOT match 'pp_standard','sagepay_server','cod', and 'bank_transfer'.

A quick query I would use for that would be something like:

Code: Select all

SELECT order_id, payment_code FROM oc_order 
where payment_code NOT LIKE '%pp_standard%' 
AND payment_code NOT LIKE '%sagepay_server%'
AND payment_code NOT LIKE '%cod%'  
AND payment_code NOT LIKE '%bank_transfer%'
/*AND payment_code NOT LIKE '%amazon.amazon%' */
The commented line is there if you want to include the OpenBay Amazon code. Just uncomment it to include it in the query. First time I would leave it out and see what payment_codes show up in the query result.

I hope that helps.

Good luck!

Newbie

Posts

Joined
Sat Nov 16, 2013 8:53 am

Post by reececropley » Thu Apr 07, 2016 3:25 pm

Thanks, Ill give that a go. Unfortunately I have caused another error on the site from trying to fix something else. Ill have a crack at this once i've finished fixing this.

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by reececropley » Mon Apr 11, 2016 11:37 pm

Hello, I have changed all the blank lines and updated the old payment codes to the new. The only payment code that it doesn't work on now is OpenBay's 'amazon.amazon'.

OpenBay's support team have logged in and installed the latest version for me. Ill ask the same question to them and show them the error code. But any thoughts from this thread?

New member

Posts

Joined
Fri Mar 22, 2013 7:29 pm

Post by pm-netti » Mon Apr 11, 2016 11:55 pm

There is correct payment_codes to version 2.2.

https://github.com/opencart/opencart/tr ... er/payment

( filenames without '.php')

Image
- - - OpenCart Upgrade Service - - -


User avatar
Active Member

Posts

Joined
Sat Apr 07, 2012 11:22 pm
Location - Kittilä-Finland
Who is online

Users browsing this forum: No registered users and 6 guests