* * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. * * $Id: compteur_groupe.php,v 1.1 2005/07/23 13:28:59 rodolphe Exp $ * $Source: /srv/cvs/sources/dolibarr/dolibarr/htdocs/energie/Attic/compteur_groupe.php,v $ * */ /** \file htdocs/energie/compteur_groupe.php \ingroup energie \brief Fiche de gestion des groupes des compteurs \version $Revision: 1.1 $ */ require("./pre.inc.php"); if ($_POST["action"] == 'addvalue') { $compteur = new EnergieCompteur($db, $user); if ( $compteur->fetch($_GET["id"]) == 0) { if ( $compteur->AddGroup($_POST["groupe"]) == 0) { Header("Location: compteur.php?id=".$_GET["id"]); } } } /* * */ llxHeader($langs, '',$langs->trans("Compteur"),"Compteur"); if ($_GET["id"] > 0) { $compteur = new EnergieCompteur($db, $user); if ( $compteur->fetch($_GET["id"]) == 0) { $head[0][0] = DOL_URL_ROOT.'/energie/compteur.php?id='.$compteur->id; $head[0][1] = "Compteur"; $h++; $head[$h][0] = DOL_URL_ROOT.'/energie/compteur_graph.php?id='.$compteur->id; $head[$h][1] = "Graph"; $h++; $head[$h][0] = DOL_URL_ROOT.'/energie/compteur_groupe.php?id='.$compteur->id; $head[$h][1] = "Groupe"; $h++; $a = 2; dolibarr_fiche_head($head, $a, $soc->nom); print ''; print ""; print '"; print "
".$langs->trans("Compteur")."'; print $compteur->libelle; print "

"; $html = new Form($db); print '
'; print ''; print ''; $var=!$var; print ""; $compteur->GroupsAvailable(); print ''; print ''; print "
Groupe'; print $html->select_array("groupe", $compteur->groups_available); print '

"; print ''; print "
\n"; } else { /* Commande non trouvée */ print "Compteur inexistant"; } } else { print "Compteur inexistant"; } $db->close(); llxFooter("Dernière modification $Date: 2005/07/23 13:28:59 $ révision $Revision: 1.1 $"); ?>