Model/Action/OrderCaptureAction.php
protected function createPayment($response)
    {
        $payment = oxNew(\OxidEsales\PayPalModule\Model\OrderPayment::class);
        $payment->setDate($this->getDate());
        $payment->setTransactionId($response->getTransactionId());
        $payment->setCorrelationId($response->getCorrelationId());
        $payment->setAction('capture');
        $payment->setStatus($response->getPaymentStatus());
        $payment->setAmount($response->getCapturedAmount());
        $payment->setCurrency($response->getCurrency());

        return $payment;
    }
protected function createPayment($response)
    {
        $payment = oxNew(\OxidEsales\PayPalModule\Model\OrderPayment::class);
        $payment->setDate($this->getDate());
        $payment->setTransactionId($response->getTransactionId());
        $payment->setCorrelationId($response->getCorrelationId());
        $payment->setAction('capture');
        $payment->setStatus($response->getPaymentStatus());
        $payment->setAmount($response->getCapturedAmount());
        $payment->setCurrency($response->getCurrency());

        return $payment;
    }
protected function createPayment ( $ response ) { $ payment = oxNew ( \ OxidEsales \ PayPalModule \ Model \ OrderPayment :: class ) ; $ payment -> setDate ( $ this -> getDate ( ) ) ; $ payment -> setTransactionId ( $ response -> getTransactionId ( ) ) ; $ payment -> setCorrelationId ( $ response -> getCorrelationId ( ) ) ; $ payment -> setAction ( 'capture' ) ; $ payment -> setStatus ( $ response -> getPaymentStatus ( ) ) ; $ payment -> setAmount ( $ response -> getCapturedAmount ( ) ) ; $ payment -> setCurrency ( $ response -> getCurrency ( ) ) ; return $ payment ; }
Creates Payment object with PayPal response data.

@param object $response

@return \OxidEsales\PayPalModule\Model\OrderPayment::class
Creates Payment object with PayPal response data .