Commit e47ccf3f authored by mbriand's avatar mbriand
Browse files

bleh

parent db412fca
......@@ -390,16 +390,8 @@ class interfaceweb
"AND archive != '1' " .
"ORDER BY nom_cpt");
$req3 = new requete($this->db,
"SELECT id_comptoir,nom_cpt " .
"FROM cpt_comptoir " .
"WHERE id_groupe_vendeur IN (".$this->user->get_groups_csv().") AND type_cpt = '2' " .
"AND archive != '1' " .
"ORDER BY nom_cpt");
if ( $req->lines > 0
|| $req2->lines > 0
|| $req3->lines > 0
|| $this->user->is_in_group("root")
|| $this->user->is_in_group("moderateur_site")
|| $this->user->is_in_group("compta_admin")
......@@ -452,14 +444,6 @@ class interfaceweb
$class="";
}
/* Comptoirs */
while(list($id,$nom)=$req3->get_row())
{
$this->buffer .= "menu_assos[".$i."]='<a $class href=\"".$topdir."comptoir/bureau.php?id_comptoir=$id\">Comptoir : ".str_replace("'","\'",$nom)."</a>';";
$i++;
$class="";
}
/* Admins comptoirs */
if( $req2->lines > 4 )
{
......
......@@ -64,6 +64,7 @@ else
$sublist->add("<a href=\"".$topdir."user/emprunts.php\">Mes emprunts de matériel</a>");
$sublist->add("<a href=\"".$topdir."news.php\">Proposer une nouvelle</a>");
$sublist->add("<a href=\"".$topdir."affiches.php\">Proposer une affiche</a>");
$sublist->add("<a href=\"".$topdir."salle.php?page=reservation\">Reserver une salle</a>");
$sublist->add("<a href=\"".$topdir."emprunt.php\">Reserver du matériel</a>");
$board->add($sublist,true);
......@@ -111,7 +112,20 @@ elseif($site->user->is_in_group("root") || $site->user->is_in_group("moderateur_
$board->add($sublist,true);
}
/* Comptoirs */
$req = new requete($this->db,
"SELECT id_comptoir,nom_cpt " .
"FROM cpt_comptoir " .
"WHERE id_groupe_vendeur IN (".$this->user->get_groups_csv().") AND type_cpt = '2' " .
"AND archive != '1' " .
"ORDER BY nom_cpt");
if ($req->lines > 0)
{
$sublist = new itemlist("Gestion assos/clubs","boxlist");
while(list($id,$nom)=$req->get_row())
$sublist->add("<a href=\"".$topdir."comptoir/bureau.php?id_comptoir=$id\">Comptoir : ".$nom."</a>");
$board->add($sublist,true);
}
$cts->add($board);
$site->add_contents($cts);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment