예제 #1
0
파일: Customer.php 프로젝트: jurgisk/sdk
 public function setVIP($bool = true)
 {
     if (empty($this->_customerFid)) {
         throw new \RuntimeException("You cannot set a customers VIP status before setting a customer fid");
     }
     $ep = $this->_getEndpoint();
     $this->_processRequest($ep->setVip(DataNodePropertyPayload::create($this->_customerFid, $bool)));
     return $this;
 }
예제 #2
0
파일: Customer.php 프로젝트: fortifi/sdk
 public function setCurrency($currency = 'USD')
 {
     if (empty($this->_customerFid)) {
         throw new \RuntimeException("You cannot set a customers currency before setting a customer fid");
     }
     if (strlen($currency) != 3) {
         throw new \RuntimeException("You must specify the currency in ISO 4217 format");
     }
     $ep = $this->_getEndpoint();
     $this->_processRequest($ep->setCurrency(DataNodePropertyPayload::create($this->_customerFid, $currency)));
     return $this;
 }
예제 #3
0
 /**
  * @param string $fid
  * @param        $value
  *
  * @return BoolResponse
  */
 public function setAccountManager($fid, $value)
 {
     $payload = DataNodePropertyPayload::create($fid, $value);
     $ep = CustomerEndpoint::bound($this->getApi());
     return $ep->setAccountManager($payload)->get();
 }