]> git.llucax.com Git - mecon/meconlib.git/blobdiff - lib/MECON/HTML/ArbolDB.php
BugFix.
[mecon/meconlib.git] / lib / MECON / HTML / ArbolDB.php
index 9638922f32696bf5614277e3170ab077070baab1..dedf3b93b37d21b6e2c5f3dd2c4f5e34999b5b4f 100644 (file)
@@ -141,6 +141,8 @@ class MECON_HTML_ArbolDB extends MECON_HTML_Arbol
             $this->link = $dbdata['link']; 
         if(isset($dbdata['where']))
             $this->where = $dbdata['where'];
             $this->link = $dbdata['link']; 
         if(isset($dbdata['where']))
             $this->where = $dbdata['where'];
+        if(isset($dbdata['habilitado']))
+            $this->habilitado = $dbdata['habilitado'];
         if(isset($dbdata['order']))
             $this->order = ' ORDER BY '.$dbdata['nombre'].' '.$dbdata['order']; 
         $this->db = $dbdata['db']; 
         if(isset($dbdata['order']))
             $this->order = ' ORDER BY '.$dbdata['nombre'].' '.$dbdata['order']; 
         $this->db = $dbdata['db']; 
@@ -188,6 +190,8 @@ class MECON_HTML_ArbolDB extends MECON_HTML_Arbol
             $sql .= ' AND';
         } elseif ($this->where)
           $sql .= $this->where;
             $sql .= ' AND';
         } elseif ($this->where)
           $sql .= $this->where;
+        if(isset($this->habilitado))
+          $sql .= " AND ".$this->habilitado." = 1 ";
         $sql .= $this->order;
         $result = $this->db->query($sql);
         if(DB::isError($result))
         $sql .= $this->order;
         $result = $this->db->query($sql);
         if(DB::isError($result))