コード例 #1
0
 protected function fillTransaction(SimpleXMLElement $xml)
 {
     $hpsPopulator = new HpsTxnPopulator();
     $hpsPopulator->setReturnUrl($this->returnUrl)->setExpiryUrl($this->expiryUrl)->setPageSetId($this->pageSetId);
     $detailsPopulator = new TxnDetailsPopulator();
     $detailsPopulator->setReference($this->reference)->setAmount($this->amount);
     $hpsPopulator->createElement($xml->addChild('HpsTxn'));
     $detailsPopulator->createElement($xml->addChild('TxnDetails'));
 }
コード例 #2
0
 protected function fillTransaction(SimpleXMLElement $xml)
 {
     $hpsPopulator = new HpsTxnPopulator();
     $hpsPopulator->setReturnUrl($this->getReturnUrl())->setExpiryUrl($this->getExpiryUrl())->setErrorUrl($this->errorUrl)->setPageSetId($this->getPageSetId())->setMethod(SetupMethod::FULL);
     $detailsPopulator = new TxnDetailsWithoutRiskPopulator();
     $detailsPopulator->setReference($this->getReference())->setAmount($this->getAmount())->setCaptureMethod(CaptureMethod::ECOMM)->setMerchantUrl($this->merchantUrl)->setDescription($this->description);
     $hpsPopulator->createElement($xml->addChild('HpsTxn'));
     $detailsPopulator->createElement($xml->addChild('TxnDetails'));
     $cardTxn = $xml->addChild('CardTxn');
     $cardTxn->addChild('method', 'auth');
 }