- $this->padre = $dbdata['id_padre'];
- $this->tabla = $dbdata['tabla'];
- $this->nombre = $dbdata['nombre'];
- $this->id = $dbdata['id'];
- $this->link = $dbdata['link'];
- $this->db = $dbdata['db'];
- $dat = $this->BuscarHijos(0);
- parent::HTML_Arbol($dat, $imagen);
+ if(isset($dbdata['id_padre']))
+ $this->padre = $dbdata['id_padre'];
+ $this->tabla = $dbdata['tabla'];
+ $this->nombre = $dbdata['nombre'];
+ $this->id = $dbdata['id'];
+ // FIXME - Deprecated!
+ if(isset($dbdata['prepend_link']))
+ $link_append = $dbdata['prepend_link'];
+ if(isset($dbdata['link']))
+ $this->link = $dbdata['link'];
+ if(isset($dbdata['where']))
+ $this->where = $dbdata['where'];
+ if(isset($dbdata['order']))
+ $this->order = ' ORDER BY '.$dbdata['nombre'].' '.$dbdata['order'];
+ $this->db = $dbdata['db'];
+ parent::HTML_Arbol(array(), $titulo, $link_append);
+ $this->datos = $this->BuscarHijos(0);