Hallo zusammen,
ich hatte gerade bei einem Kunden den Effekt, dass die Ratenzahlung powered by PayPal trotz korrekter Konfiguration nicht angezeigt wurde. Aktuell läuft dort die Version 2.0.5.1 mit PayPal 1.46, mit Shop-Version 2.0.4.2 hat es wohl noch funktioniert.
Folgendes ist mir aufgefallen:
In /includes/external/paypal/classes/PayPalCommon.php:78 wird ein Array zurückgegeben:
function get_min_installment_amount
() { return array( 'amount' => 99.00, 'currency' => 'EUR', ); } In /includes/modules/payment/paypalinstallment.php:71 wird das zurückgegebene Array mit dem Warenkorbwert verglichen. Funktioniert natürlich nicht.
if ($this->total_amount > $this->get_min_installment_amount()) { $this->presentment_array = $this->get_presentment($this->total_amount, $order->info['currency'], $order->billing['country']['iso_code_2']); if (count($this->presentment_array) < 1) { $this->enabled = false; } } else { $this->enabled = false; } } Ich habe jetzt eine Anpassung wie folgt vorgenommen (ist glaube ich nicht bis PHP 5.6 abwärtskompatibel):
if ($this->total_amount > $this->get_min_installment_amount()['amount']) { $this->presentment_array = $this->get_presentment($this->total_amount, $order->info['currency'], $order->billing['country']['iso_code_2']); if (count($this->presentment_array) < 1) { $this->enabled = false; } } else { $this->enabled = false; } Soweit ich es gesehen habe sind alle Dateien auf dem aktuellsten Stand. Wenn es nicht so ist dürft ihr mich gerne korrigieren.
Schönen Tag noch,
Dominik
[
EDIT Tomcraft 30.06.2020: Shopversion korrigiert, siehe:
FAQ: Wichtiger Hinweis bzgl. Angabe der Shopversion!]