@@ -51,18 +51,30 @@ discard block |
||
| 51 | 51 | * order details |
| 52 | 52 | **/ |
| 53 | 53 | protected $AmountInput = 0; |
| 54 | + |
|
| 55 | + /** |
|
| 56 | + * @param double $v |
|
| 57 | + */ |
|
| 54 | 58 | public function setAmountInput($v) |
| 55 | 59 | { |
| 56 | 60 | $this->AmountInput = $v; |
| 57 | 61 | } |
| 58 | 62 | |
| 59 | 63 | protected $MerchantReference = ""; |
| 64 | + |
|
| 65 | + /** |
|
| 66 | + * @param integer $v |
|
| 67 | + */ |
|
| 60 | 68 | public function setMerchantReference($v) |
| 61 | 69 | { |
| 62 | 70 | $this->MerchantReference = $v; |
| 63 | 71 | } |
| 64 | 72 | |
| 65 | 73 | protected $CurrencyInput = "NZD"; |
| 74 | + |
|
| 75 | + /** |
|
| 76 | + * @param string $v |
|
| 77 | + */ |
|
| 66 | 78 | public function setCurrencyInput($v) |
| 67 | 79 | { |
| 68 | 80 | $this->CurrencyInput = $v; |
@@ -84,11 +96,19 @@ discard block |
||
| 84 | 96 | * details of the redirection |
| 85 | 97 | **/ |
| 86 | 98 | protected $UrlFail = ""; |
| 99 | + |
|
| 100 | + /** |
|
| 101 | + * @param false|string $v |
|
| 102 | + */ |
|
| 87 | 103 | public function setUrlFail($v) |
| 88 | 104 | { |
| 89 | 105 | $this->UrlFail = $v; |
| 90 | 106 | } |
| 91 | 107 | protected $UrlSuccess = ""; |
| 108 | + |
|
| 109 | + /** |
|
| 110 | + * @param false|string $v |
|
| 111 | + */ |
|
| 92 | 112 | public function setUrlSuccess($v) |
| 93 | 113 | { |
| 94 | 114 | $this->UrlSuccess = $v; |
@@ -98,11 +118,19 @@ discard block |
||
| 98 | 118 | * Details to use stored cards |
| 99 | 119 | */ |
| 100 | 120 | protected $EnableAddBillCard = 0; |
| 121 | + |
|
| 122 | + /** |
|
| 123 | + * @param integer $v |
|
| 124 | + */ |
|
| 101 | 125 | public function setEnableAddBillCard($v) |
| 102 | 126 | { |
| 103 | 127 | $this->EnableAddBillCard = $v; |
| 104 | 128 | } |
| 105 | 129 | protected $BillingId = 0; |
| 130 | + |
|
| 131 | + /** |
|
| 132 | + * @param string $v |
|
| 133 | + */ |
|
| 106 | 134 | public function setBillingId($v) |
| 107 | 135 | { |
| 108 | 136 | $this->BillingId = $v; |
@@ -123,6 +123,9 @@ |
||
| 123 | 123 | |
| 124 | 124 | |
| 125 | 125 | |
| 126 | + /** |
|
| 127 | + * @param OrderForm $form |
|
| 128 | + */ |
|
| 126 | 129 | public function processViaPostRatherThanPxPay($data, $form, $cardToUse) |
| 127 | 130 | { |
| 128 | 131 | |
@@ -116,7 +116,7 @@ discard block |
||
| 116 | 116 | * @see DPSPayment->getPaymentFormRequirements() for an example on how |
| 117 | 117 | * this is implemented. |
| 118 | 118 | * |
| 119 | - * @return array |
|
| 119 | + * @return FieldList |
|
| 120 | 120 | */ |
| 121 | 121 | public function getPaymentFormRequirements() |
| 122 | 122 | { |
@@ -226,7 +226,7 @@ discard block |
||
| 226 | 226 | /** |
| 227 | 227 | * are you running in test mode? |
| 228 | 228 | * |
| 229 | - * @return Boolean |
|
| 229 | + * @return boolean|null |
|
| 230 | 230 | */ |
| 231 | 231 | protected function isTest() |
| 232 | 232 | { |
@@ -35,6 +35,10 @@ discard block |
||
| 35 | 35 | # Return the value of the specified top-level attribute. |
| 36 | 36 | # This method can only return attributes of the root element. |
| 37 | 37 | # If the attribute is not found, return "". |
| 38 | + |
|
| 39 | + /** |
|
| 40 | + * @param string $attribute |
|
| 41 | + */ |
|
| 38 | 42 | public function get_attribute($attribute) |
| 39 | 43 | { |
| 40 | 44 | $attributes = $this->xml_value_[0]["attributes"]; |
@@ -46,6 +50,10 @@ discard block |
||
| 46 | 50 | # For example, "Link/ServerOk" refers to the ServerOk element |
| 47 | 51 | # nested in the Link element (nested in the root element). |
| 48 | 52 | # If the element is not found, return "". |
| 53 | + |
|
| 54 | + /** |
|
| 55 | + * @param string $element |
|
| 56 | + */ |
|
| 49 | 57 | public function get_element_text($element) |
| 50 | 58 | { |
| 51 | 59 | $index = $this->get_element_index($element, 0); |
@@ -120,6 +128,10 @@ discard block |
||
| 120 | 128 | #****************************************************************************** |
| 121 | 129 | # Create a request for the PxPay interface |
| 122 | 130 | #****************************************************************************** |
| 131 | + |
|
| 132 | + /** |
|
| 133 | + * @param PxPayRequest $request |
|
| 134 | + */ |
|
| 123 | 135 | public function makeRequest($request) |
| 124 | 136 | { |
| 125 | 137 | #Validate the Request |
@@ -195,6 +207,9 @@ discard block |
||
| 195 | 207 | $this->PxPayMessage(); |
| 196 | 208 | } |
| 197 | 209 | |
| 210 | + /** |
|
| 211 | + * @param integer $EnableBillAddCard |
|
| 212 | + */ |
|
| 198 | 213 | public function setEnableAddBillCard($EnableBillAddCard) |
| 199 | 214 | { |
| 200 | 215 | $this->EnableAddBillCard = $EnableBillAddCard; |
@@ -297,6 +312,9 @@ discard block |
||
| 297 | 312 | { |
| 298 | 313 | } |
| 299 | 314 | |
| 315 | + /** |
|
| 316 | + * @param integer $BillingId |
|
| 317 | + */ |
|
| 300 | 318 | public function setBillingId($BillingId) |
| 301 | 319 | { |
| 302 | 320 | $this->BillingId = $BillingId; |
@@ -313,6 +331,10 @@ discard block |
||
| 313 | 331 | { |
| 314 | 332 | return $this->TxnType; |
| 315 | 333 | } |
| 334 | + |
|
| 335 | + /** |
|
| 336 | + * @param string $CurrencyInput |
|
| 337 | + */ |
|
| 316 | 338 | public function setCurrencyInput($CurrencyInput) |
| 317 | 339 | { |
| 318 | 340 | $this->CurrencyInput = $CurrencyInput; |
@@ -325,6 +347,10 @@ discard block |
||
| 325 | 347 | { |
| 326 | 348 | $this->MerchantReference = $MerchantReference; |
| 327 | 349 | } |
| 350 | + |
|
| 351 | + /** |
|
| 352 | + * @return integer |
|
| 353 | + */ |
|
| 328 | 354 | public function getMerchantReference() |
| 329 | 355 | { |
| 330 | 356 | return $this->MerchantReference; |
@@ -361,6 +387,10 @@ discard block |
||
| 361 | 387 | { |
| 362 | 388 | $this->TxnData3 = $TxnData3; |
| 363 | 389 | } |
| 390 | + |
|
| 391 | + /** |
|
| 392 | + * @param string $TxnId |
|
| 393 | + */ |
|
| 364 | 394 | public function setTxnId($TxnId) |
| 365 | 395 | { |
| 366 | 396 | $this->TxnId = $TxnId; |