Open Journal Systems  3.3.0
lib/vendor/omnipay/paypal/src/Message/RefundRequest.php
1 <?php
2 
3 namespace Omnipay\PayPal\Message;
4 
9 {
10  public function getData()
11  {
12  $this->validate('transactionReference');
13 
14  $data = $this->getBaseData();
15  $data['METHOD'] = 'RefundTransaction';
16  $data['TRANSACTIONID'] = $this->getTransactionReference();
17  $data['REFUNDTYPE'] = 'Full';
18  if ($this->getAmount() > 0) {
19  $data['REFUNDTYPE'] = 'Partial';
20  $data['AMT'] = $this->getAmount();
21  $data['CURRENCYCODE'] = $this->getCurrency();
22  }
23 
24  return $data;
25  }
26 }
Omnipay\Common\Message\AbstractRequest\getCurrency
getCurrency()
Definition: lib/vendor/omnipay/common/src/Omnipay/Common/Message/AbstractRequest.php:391
Omnipay\PayPal\Message\RefundRequest\getData
getData()
Definition: lib/vendor/omnipay/paypal/src/Message/RefundRequest.php:10
Omnipay\PayPal\Message\AbstractRequest
Definition: lib/vendor/omnipay/paypal/src/Message/AbstractRequest.php:35
Omnipay\Common\Message\AbstractRequest\getTransactionReference
getTransactionReference()
Definition: lib/vendor/omnipay/common/src/Omnipay/Common/Message/AbstractRequest.php:508
Omnipay\Common\Message\AbstractRequest\validate
validate()
Definition: lib/vendor/omnipay/common/src/Omnipay/Common/Message/AbstractRequest.php:226
Omnipay\PayPal\Message\RefundRequest
Definition: lib/vendor/omnipay/paypal/src/Message/RefundRequest.php:8
Omnipay\PayPal\Message\AbstractRequest\getBaseData
getBaseData()
Definition: lib/vendor/omnipay/paypal/src/Message/AbstractRequest.php:282
Omnipay\PayPal\Message
Definition: lib/vendor/omnipay/paypal/src/Message/AbstractRequest.php:6
Omnipay\Common\Message\AbstractRequest\getAmount
getAmount()
Definition: lib/vendor/omnipay/common/src/Omnipay/Common/Message/AbstractRequest.php:327