Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Model/Payment.php update #13

Closed
wants to merge 1 commit into from

Conversation

piotrBurewicz
Copy link

:1127, changed STATE_PAYMENT_REVIEW to STATE_PROCESSING

:1127, changed STATE_PAYMENT_REVIEW to STATE_PROCESSING
@gitwasi gitwasi mentioned this pull request Mar 26, 2013
@openpayu
Copy link
Contributor

@piotrBurewicz,

You have to change that like:

    public function updatePaymentStatusCompleted($payment)
    {
        $transaction = $payment->setTransactionId($this->_transactionId);
        $transaction->setPreparedMessage("PayU - " . Mage::helper('payu_account')->__('The transaction completed successfully.'));

        if(intval(Mage::getStoreConfig('payment/payu_account/selfreturn')))
        {
            $payment->setIsTransactionApproved(true);
            $payment->setIsTransactionClosed(true);
        }

        $comment = $this->_order->setState((intval(Mage::getStoreConfig('payment/payu_account/selfreturn'))) ? Mage_Sales_Model_Order::STATE_PROCESSING : Mage_Sales_Model_Order::STATE_PAYMENT_REVIEW, true, "PayU - " . Mage::helper('payu_account')->__('The transaction completed successfully.'), false)
            ->sendOrderUpdateEmail(true, "PayU - " . Mage::helper('payu_account')->__('Thank you.') . " " . Mage::helper('payu_account')->__('The transaction completed successfully.'))
            ->save();
        $transaction->save();
    }

@regdos
Copy link
Contributor

regdos commented Aug 23, 2016

Fix in #58

@regdos regdos closed this Aug 23, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants