Esempio n. 1
0
 /**
  * Get url if the cell is a link
  * 
  * @return string
  */
 public function getLink()
 {
     $link = $this->field->getCellLink();
     if ($link === null) {
         return;
     }
     return preg_replace_callback('~\\{([^}]+)\\}~', function ($matches) {
         if ($this->row === null) {
             throw new \LogicException('Cell doesn\'t belongs to a row');
         }
         return $this->row->getMetadataProperty($matches[1]);
     }, $link);
 }