Ejemplo n.º 1
0
 /**
  * Recupera os registros de um link
  * @author Hugo Ferreira da silva
  * @link http://www.hufersil.com.br
  * @param string $linkName 
  * @param mixed $pk Nome ou valor da chave 
  * @param mixed $pkValue Valor da chave
  * @return array Links encontrados
  */
 public function fetchLink($linkName, $pk, $pkValue = null)
 {
     $res = $this->get($pk, $pkValue);
     $res = $this->obj->fetchLink($linkName);
     $list = array();
     if ($res instanceof Lumine_Base) {
         $list[] = $res->toArray();
     } else {
         foreach ($res as $item) {
             $list[] = $item->toArray();
         }
     }
     return $list;
 }