示例#1
0
 /**
  * @param \Spryker\Zed\Payone\Business\Api\Request\Container\AbstractRequestContainer $container
  *
  * @return void
  */
 protected function applyStandardParameter(AbstractRequestContainer $container)
 {
     if ($container->getPortalid() === null) {
         $container->setPortalid($this->standardParameter->getPortalId());
     }
     if ($container->getAid() === null) {
         $container->setAid($this->standardParameter->getAid());
     }
     if ($container->getMid() === null) {
         $container->setMid($this->standardParameter->getMid());
     }
     if ($container->getEncoding() === null) {
         $container->setEncoding($this->standardParameter->getEncoding());
     }
     if ($container->getMode() === null) {
         $container->setMode($this->modeDetector->getMode());
     }
     if ($container->getLanguage() === null) {
         $container->setLanguage($this->standardParameter->getLanguage());
     }
     if ($container->getApiVersion() === null) {
         $container->setApiVersion($this->standardParameter->getApiVersion());
     }
     if ($container->getResponsetype() === null) {
         $container->setResponsetype($this->standardParameter->getResponseType());
     }
 }
示例#2
0
 /**
  * @param \Spryker\Zed\Payone\Business\Api\Request\Container\AbstractRequestContainer $container
  *
  * @return void
  */
 protected function setStandardParameter(AbstractRequestContainer $container)
 {
     $container->setApiVersion(PayoneApiConstants::API_VERSION_3_9);
     $container->setEncoding($this->standardParameter->getEncoding());
     $container->setKey($this->hashGenerator->hash($this->standardParameter->getKey()));
     $container->setMid($this->standardParameter->getMid());
     $container->setPortalid($this->standardParameter->getPortalId());
     $container->setMode($this->modeDetector->getMode());
 }