From f2c6d3c31f8a5365c93d2e69742b32d76173d185 Mon Sep 17 00:00:00 2001 From: Joshua Lewis Date: Mon, 17 Jun 2019 13:55:42 -0400 Subject: [PATCH] added mapping for COMPLETE --- code/Bitpay/BPCheckout/Model/IpnManagement.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/code/Bitpay/BPCheckout/Model/IpnManagement.php b/code/Bitpay/BPCheckout/Model/IpnManagement.php index b9016cd..516e3e8 100755 --- a/code/Bitpay/BPCheckout/Model/IpnManagement.php +++ b/code/Bitpay/BPCheckout/Model/IpnManagement.php @@ -94,18 +94,18 @@ public function postIpn() $order = $this->getOrder($orderid); #now update the order - switch ($event['name']) { case 'invoice_completed': $order->addStatusHistoryComment('BitPay Invoice ' . $order_invoice . ' status has changed to Completed.'); + $order->setState(Order::STATE_PROCESSING)->setStatus(Order::STATE_PROCESSING); $order->save(); return true; break; case 'invoice_confirmed': - #pending or pcoressing from plugin settings + #pending or processing from plugin settings $order->addStatusHistoryComment('BitPay Invoice ' . $order_invoice . ' processing has been completed.'); if($bitpay_ipn_mapping != 'processing'):