public function refund(
        $orderId,
        $isPartial = false,
        $amount = null,
        HpsOrderData $orderData = null
    ) {
        $payload = array(
            'Amount' => $this->formatAmount($amount),
            'CurrencyCode' => $this->currencyStringToNumeric(
                $orderData->currencyCode
            ),
            'OrderId' => $orderId,
            'TransactionType' => 'WT',
        );
        return $this->submitTransaction($payload, 'cmpi_refund');
    }
public function refund(
        $orderId,
        $isPartial = false,
        $amount = null,
        HpsOrderData $orderData = null
    ) {
        $payload = array(
            'Amount' => $this->formatAmount($amount),
            'CurrencyCode' => $this->currencyStringToNumeric(
                $orderData->currencyCode
            ),
            'OrderId' => $orderId,
            'TransactionType' => 'WT',
        );
        return $this->submitTransaction($payload, 'cmpi_refund');
    }
public function refund ( $ orderId , $ isPartial = false , $ amount = null , HpsOrderData $ orderData = null ) { $ payload = array ( 'Amount' => $ this -> formatAmount ( $ amount ) , 'CurrencyCode' => $ this -> currencyStringToNumeric ( $ orderData -> currencyCode ) , 'OrderId' => $ orderId , 'TransactionType' => 'WT' , ) ; return $ this -> submitTransaction ( $ payload , 'cmpi_refund' ) ; }
Responsible for crediting the consumer some portion or all of the original
settlement amount. Multiple refunds can be processed against the original
capture transaction.

@param string       $orderId   order id from Cardinal
@param boolean      $isPartial flag for partial refund
@param string       $amount    amount to be refunded
@param HpsOrderData $orderData Cardinal/MasterPass specific data

@return object
Responsible for crediting the consumer some portion or all of the original settlement amount . Multiple refunds can be processed against the original capture transaction .