Esempio n. 1
0
 public function testCreate()
 {
     $instance = FidPayload::create('FID:1234:abcde:fg');
     $this->assertEquals('FID:1234:abcde:fg', $instance->fid);
     $test = MarkDatePayload::create('FID:1234:abcde:fg');
     $this->assertInstanceOf('\\Fortifi\\FortifiApi\\Foundation\\Payloads\\MarkDatePayload', $test);
 }
Esempio n. 2
0
 /**
  * @param int|null $timestamp
  *
  * @return $this
  */
 public function markPurchased($timestamp = null)
 {
     if (empty($this->_customerFid)) {
         throw new \RuntimeException("You cannot mark a customer as purchased before setting a customer fid");
     }
     $ep = $this->_getEndpoint();
     $this->_processRequest($ep->markPurchased(MarkDatePayload::create($this->_customerFid, $timestamp)));
     return $this;
 }