X-Git-Url: https://git.llucax.com/mecon/meconlib.git/blobdiff_plain/7009e11967b2ad1cc2a88042d32800270b9ceecc..dcac3a1a16dfba59dd3bf07b0cbc8ea47f9bbc74:/lib/MECON/Dependencia.php?ds=inline diff --git a/lib/MECON/Dependencia.php b/lib/MECON/Dependencia.php index 1238652..6b01f1f 100644 --- a/lib/MECON/Dependencia.php +++ b/lib/MECON/Dependencia.php @@ -129,7 +129,7 @@ class MECON_Dependencia { if(DB::isError($result)) trigger_error($result->getMessage("query mal hecho"), E_USER_ERROR); while($row = $result->fetchRow()) - $agentes[] = new MECON_Agente($row[0]); + $agentes[$row[0]] = new MECON_Agente($this->_db, $row[0]); //Contratados $sql = "SELECT nrodoc FROM Contratados.Contratados @@ -138,7 +138,7 @@ class MECON_Dependencia { if(DB::isError($result)) trigger_error($result->getMessage("query mal hecho"), E_USER_ERROR); while($row = $result->fetchRow()) - $agentes[] = new MECON_Agente($row[0]); + $agentes[$row[0]] = new MECON_Agente($this->_db, $row[0]); return $agentes; }