Fix: La mise a jour des nouveaux droits en automatique ne fonctionnait pas.

This commit is contained in:
Laurent Destailleur 2005-05-14 14:35:23 +00:00
parent d0d1212171
commit ef06e53719

View File

@ -439,6 +439,16 @@ class DolibarrModules
$err=0; $err=0;
//print $this->rights_class." ".sizeof($this->rights)."<br>"; //print $this->rights_class." ".sizeof($this->rights)."<br>";
// Test si module actif
$sql_del = "SELECT value FROM ".MAIN_DB_PREFIX."const WHERE name = '".$this->const_name."';";
$resql=$this->db->query($sql_del);
if ($resql) {
$obj=$this->db->fetch_object($resql);
if ($obj->value) {
// Si module actif
foreach ($this->rights as $key => $value) foreach ($this->rights as $key => $value)
{ {
$r_id = $this->rights[$key][0]; $r_id = $this->rights[$key][0];
@ -482,6 +492,8 @@ class DolibarrModules
} }
} }
} }
}
}
return $err; return $err;
} }