function getList($params = NULL, $proyection = '*', $order = '1', $limit = '') { if ($this->db != NULL) { $this->db->read($this->table, $proyection, $params); $r = array(); while ($param = $this->db->getRow()) { $artist = new Artist(); $artist->set($param); $r[] = $artist; } return $r; } return NULL; }
function getList($pagina = 1, $orden = "", $nrpp = Configuracion::NRPP, $condicion = "1=1", $parametros = array()) { $ordenPredeterminado = "{$orden}, email"; if (trim($orden) === "" || trim($orden) === NULL) { $ordenPredeterminado = "titulo"; } $registroInicial = ($pagina - 1) * $nrpp; $this->bd->select($this->tabla, "*", $condicion, $parametros, $ordenPredeterminado, "{$registroInicial}, {$nrpp}"); $r = array(); while ($fila = $this->bd->getRow()) { $artista = new Artist(); $artista->set($fila); $r[] = $artista; } return $r; }