protected function getNotifyUrl(ExtendedDataInterface $data)
 {
     if ($data->has('notify_url')) {
         return $data->get('notify_url');
     } else {
         if (0 !== strlen($this->notifyUrl)) {
             return $this->notifyUrl;
         }
     }
 }
예제 #2
0
 protected function getCancelUrl(ExtendedDataInterface $data)
 {
     if ($data->has('cancel_url')) {
         return $data->get('cancel_url');
     } else {
         if (0 !== strlen($this->cancelUrl)) {
             return $this->cancelUrl;
         }
     }
     throw new \RuntimeException('You must configure a cancel url.');
 }
 /**
  * @param \JMS\Payment\CoreBundle\Model\ExtendedDataInterface $data
  *
  * @return string
  * @throws \RuntimeException
  */
 protected function getReturnUrl(ExtendedDataInterface $data)
 {
     if ($data->has('return_url')) {
         $url = $data->get('return_url');
         if (!empty($url)) {
             return $url;
         }
     }
     if (0 !== strlen($this->returnUrl)) {
         return $this->returnUrl;
     }
     throw new \RuntimeException('You must configure a return url.');
 }