From 7f7dafa276ea9a2a5d737f1a864e4ceaa6257523 Mon Sep 17 00:00:00 2001 From: Rodolphe Quiedeville Date: Wed, 1 Dec 2004 16:50:33 +0000 Subject: [PATCH] Nouveau fichier --- htdocs/admin/societe.php | 112 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 112 insertions(+) create mode 100644 htdocs/admin/societe.php diff --git a/htdocs/admin/societe.php b/htdocs/admin/societe.php new file mode 100644 index 00000000000..ca3f89a262b --- /dev/null +++ b/htdocs/admin/societe.php @@ -0,0 +1,112 @@ + + * + * 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$ + * $Source$ + */ + +/*! \file htdocs/admin/propale.php + \ingroup propale + \brief Page d'administration/configuration du module Propale + \version $Revision$ +*/ + +require("./pre.inc.php"); + +$langs->load("admin"); + +if (!$user->admin) + accessforbidden(); + +$codeclient_addon_var = CODECLIENT_ADDON; + +if ($_GET["action"] == 'setmod') +{ + if (dolibarr_set_const($db, "CODECLIENT_ADDON",$_GET["value"])) + { + // la constante qui a été lue en avant du nouveau set + // on passe donc par une variable pour avoir un affichage cohérent + $codeclient_addon_var = $_GET["value"]; + Header("Location: societe.php"); + } +} + +llxHeader(); + +/* + * + * + * + */ + +print_titre("Configuration du module Sociétés"); + +print "
"; + +print_titre("Module de vérification des codes client"); + +print ''; +print ''; +print ''; +print ''; +print ''; +print ''; +print "\n"; + +clearstatcache(); + +$dir = "../includes/modules/societe/"; +$handle = opendir($dir); +if ($handle) +{ + while (($file = readdir($handle))!==false) + { + if (substr($file, 0, 15) == 'mod_codeclient_' && substr($file, -3) == 'php') + { + $file = substr($file, 0, strlen($file)-4); + + require_once(DOL_DOCUMENT_ROOT ."/includes/modules/societe/".$file.".php"); + + $modCodeClient = new $file; + + print ''; + + if ($codeclient_addon_var == "$file") + { + print ''; + } + else + { + print ''; + print ''; + } + + print ''; + } + } + closedir($handle); +} +print '
NomInfoActivé 
'.$modCodeClient->nom."\n"; + print $modCodeClient->info(); + print ''; + print ''; + print '  activer
'; + +$db->close(); + +llxFooter(); +?>