Jump to content

Fatal error when confirm order by Bank Transfer or Check.


LorenzoProdon

Recommended Posts

Prestashop Version:  1.7.3.2

When a customer try to confirm order by ps_wirepayment (Bank Transfer) or by check, appears http://mysite/module/ps_wirepayment/validation and a white screen with Fatal Error string.

Orders by PayPal was OK.

I already tryed to change the string $this->module->displayName to ps_wirepayment , without success.

Any suggestion will be appreciated. Enabling debug mode i see this:

[PrestaShopException]
Fatal error
at line 985 in file classes/Tools.php

980.     * @param bool $htmlentities By default at true for parsing error message with htmlentities
981.     */
982.     public static function displayError($string = 'Fatal error', $htmlentities = true, Context $context = null)
983.     {
984.         if (defined('_PS_MODE_DEV_') && _PS_MODE_DEV_) {
985.             throw new PrestaShopException($string);
986.         } else if ('Fatal error' !== $string) {
987.             return $string;
988.         }
989. 
990.         return Context::getContext()->getTranslator()->trans('Fatal error', array(), 'Admin.Notifications.Error');


ToolsCore::displayError - [line 244 - classes/PaymentModule.php]
239. 
240.         // Does order already exists ?
241.         if (Validate::isLoadedObject($this->context->cart) && $this->context->cart->OrderExists() == false) {
242.             if ($secure_key !== false && $secure_key != $this->context->cart->secure_key) {
243.                 PrestaShopLogger::addLog('PaymentModule::validateOrder - Secure key does not match', 3, null, 'Cart', (int)$id_cart, true);
244.                 die(Tools::displayError());
245.             }
246. 
247.             // For each package, generate an order
248.             $delivery_option_list = $this->context->cart->getDeliveryOptionList();
249.             $package_list = $this->context->cart->getPackageList();


PaymentModuleCore->validateOrder - [line 64 - modules/ps_wirepayment/controllers/front/validation.php] - [9 Arguments]
59. 			'{bankwire_owner}' => Configuration::get('BANK_WIRE_OWNER'),
60. 			'{bankwire_details}' => nl2br(Configuration::get('BANK_WIRE_DETAILS')),
61. 			'{bankwire_address}' => nl2br(Configuration::get('BANK_WIRE_ADDRESS'))
62. 		);
63. 
64. 		$this->module->validateOrder($cart->id, Configuration::get('PS_OS_BANKWIRE'), $total, $this->module->displayName, NULL, $mailVars, (int)$currency->id, false, $customer->secure_key);
65. 		Tools::redirect('index.php?controller=order-confirmation&id_cart='.$cart->id.'&id_module='.$this->module->id.'&id_order='.$this->module->currentOrder.'&key='.$customer->secure_key);
66. 	}
67. }


Ps_WirepaymentValidationModuleFrontController->postProcess - [line 242 - classes/controller/Controller.php]
237.             if (!$this->content_only && ($this->display_header || (isset($this->className) && $this->className))) {
238.                 $this->setMedia();
239.             }
240. 
241.             // postProcess handles ajaxProcess
242.             $this->postProcess();
243. 
244.             if (!empty($this->redirect_after)) {
245.                 $this->redirect();
246.             }
247. 



ControllerCore->run - [line 428 - classes/Dispatcher.php]
423.             if (isset($params_hook_action_dispatcher)) {
424.                 Hook::exec('actionDispatcher', $params_hook_action_dispatcher);
425.             }
426. 
427.             // Running controller
428.             $controller->run();
429. 
430.             // Execute hook dispatcher after
431.             if (isset($params_hook_action_dispatcher)) {
432.                 Hook::exec('actionDispatcherAfter', $params_hook_action_dispatcher);
433.             }


DispatcherCore->dispatch - [line 28 - index.php]
23.  * @license   https://opensource.org/licenses/OSL-3.0 Open Software License (OSL 3.0)
24.  * International Registered Trademark & Property of PrestaShop SA
25.  */
26. 
27. require(dirname(__FILE__).'/config/config.inc.php');
28. Dispatcher::getInstance()->dispatch();
Edited by LorenzoProdon (see edit history)
Link to comment
Share on other sites

I solved today with upgrading prestashop version with 1-clickupgrade to 1.7.3.3

The are a lot of post without solution, maybe this can help someone.

Not solved yet: the error appears only when an imported customer try to create order with  bank transfer. if i create a new account it works perfect. I need that all customers imported can place an order with bank transfer.. 

EDIT: if a imported customer refresh the personal data after login, the site is ok and an order with bank transfer is ok!

Maybe i have to "refresh" users? does exist something can help me?

Edited by LorenzoProdon (see edit history)
  • Like 1
Link to comment
Share on other sites

  • 3 weeks later...

Hi LorenzoProdon.

 

I´m in the same situation.

Have you resolved the "refresh" issue?

Could be an error of the gdpr module? (acceptance of general conditions etc..)

I think that the error doesn´t exists for new customers who accept the gdpr...

 

(sorry my english, I´m spanish)

 

Link to comment
Share on other sites

  • 5 months later...
  • 4 weeks later...

Same here... i am using RTL Arabic version and English. Checkout and order confrmation page is perfectly working in english. but if a language  Arabic with RTL Enabled then, at order confrmation page getting error - some validation issue seems. i tried all available COD modules... no use. 

 

Advance thanks i anyone provide solution....

Link to comment
Share on other sites

  • 2 weeks later...
  • 1 year later...
  • 2 months later...
On 6/26/2018 at 8:39 AM, LorenzoProdon said:

I solved today with upgrading prestashop version with 1-clickupgrade to 1.7.3.3

The are a lot of post without solution, maybe this can help someone.

Not solved yet: the error appears only when an imported customer try to create order with  bank transfer. if i create a new account it works perfect. I need that all customers imported can place an order with bank transfer.. 

EDIT: if a imported customer refresh the personal data after login, the site is ok and an order with bank transfer is ok!

Maybe i have to "refresh" users? does exist something can help me?

Hi, what do you mean by "refresh personal data"? i get this issue with a specific customer, and every payment method get this issue.

Link to comment
Share on other sites

  • 2 months later...

I SOLVED THIS ISSUE

don't panic just increase below on your server or your hosting

php_value post_max_size 200M or ( if using hosting maybe the maximum is 128 M never mind )
php_value upload_max_filesize 200M
php_value memory_limit 300M
php_value max_execution_time 259200
php_value max_input_time 259200
php_value session.gc_maxlifetime 1200

Thank you, God Bless You,

 

Link to comment
Share on other sites

  • 2 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...