darvidc Posted April 12, 2013 Share Posted April 12, 2013 Hi I'm using PS v1.4.10.0 and downloaded the latest PS Klarna payment module v1.7.4 from the PS Shop (not Klarnas own). It installed and configured ok and it showed up in the cart OK but after choosing invoice and entering the Personal number on the next page, if I press the button to "Confirm the Order", the whole center and right column dissapears and then nothing happens? No order goes through, any ideas anybody? (I've removed the "Cloudcache" module, just to make sure) BR David C Link to comment Share on other sites More sharing options...
NemoPS Posted April 12, 2013 Share Posted April 12, 2013 Try turning errors on. In 1.4, it was config/config.inc.php, setting display_errors to on and DEBUG_SQL to true Link to comment Share on other sites More sharing options...
darvidc Posted April 12, 2013 Author Share Posted April 12, 2013 Thanks for you interest Nemo1. Ok turned error checking on and got the following error after pressing the confirm button: Fatal error: Call to undefined method Cart::getTotalShippingCost() in /storage/content/76/152276/andrummet.net/public_html/modules/klarnaprestashop/klarnaprestashop.php on line 1065 David C Link to comment Share on other sites More sharing options...
NemoPS Posted April 12, 2013 Share Posted April 12, 2013 The cart class is missing that method. I knew it was for 1.5, but haven't tested 1.4 so i don't know if it should be there actually Is that module compatible with 1.4.10? Link to comment Share on other sites More sharing options...
darvidc Posted April 12, 2013 Author Share Posted April 12, 2013 On 4/12/2013 at 8:12 AM, Nemo1 said: Is that module compatible with 1.4.10? The PS Klarna module from Prestashops own marketplace says, I qoute " Compatibility PrestaShop v1.4.0.0 - v1.5.4.0" and to quote again further down in the text "By PrestaShop The module Klarna for PrestaShop has been developed by the PrestaShop team, guaranteeing full compatibility with PrestaShop's e-commerce software". Link to comment Share on other sites More sharing options...
NemoPS Posted April 12, 2013 Share Posted April 12, 2013 Uh, well that's no guarantee really Link to comment Share on other sites More sharing options...
vekia Posted April 12, 2013 Share Posted April 12, 2013 unfortunately, exactly as Nemo said i think that module isn't work well with your store due to incompatibility with 1.4 This is free module? Link to comment Share on other sites More sharing options...
darvidc Posted April 12, 2013 Author Share Posted April 12, 2013 Is there a work around, is the method needed in 1.4 or can it be added to the code? Link to comment Share on other sites More sharing options...
NemoPS Posted April 12, 2013 Share Posted April 12, 2013 You can add this to the cart class, but it's likely to cause troubles /** * Return shipping total for the cart * * @param array $delivery_option Array of the delivery option for each address * @param booleal $use_tax * @param Country $default_country * @return float Shipping total */ public function getTotalShippingCost($delivery_option = null, $use_tax = true, Country $default_country = null) { if (is_null($delivery_option)) $delivery_option = $this->getDeliveryOption($default_country, false, false); $total_shipping = 0; $delivery_option_list = $this->getDeliveryOptionList(); foreach ($delivery_option as $id_address => $key) { if (!isset($delivery_option_list[$id_address]) || !isset($delivery_option_list[$id_address][$key])) continue; if ($use_tax) $total_shipping += $delivery_option_list[$id_address][$key]['total_price_with_tax']; else $total_shipping += $delivery_option_list[$id_address][$key]['total_price_without_tax']; } return $total_shipping; } Link to comment Share on other sites More sharing options...
vekia Posted April 12, 2013 Share Posted April 12, 2013 well, ofcourse - this is possible, but without an access to the module code is hard to say what you exactly have to change Link to comment Share on other sites More sharing options...
darvidc Posted April 12, 2013 Author Share Posted April 12, 2013 Ok thanks Nemo and Vekia. I prefer not to change/override a core class, especially if it likely to "cause problems". I think I'll just have to go back to Klarnas own "Very Buggy" v2.1.2 module that still does every thing in English as well as have the ability to change my shops tax rules very time I configure it , plus I have to do a bit of a code change in their Core file ... Hard work!!!! Link to comment Share on other sites More sharing options...
Recommended Posts