From 6302c5adeb318f7f8f4f8645c0e93d31fee781a6 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Sat, 8 Jan 2005 00:13:35 +0000 Subject: [PATCH] =?UTF-8?q?Qual:=20Uniformisation=20des=20noms=20de=20vari?= =?UTF-8?q?ables.=20On=20utilise=20MAIN=5FINFO=5FSIRET=20et=20MAIN=5FINFO?= =?UTF-8?q?=5FSIRET=20pour=20le=20SIREN=20et=20SIRET=20plutot=20que=20FAC?= =?UTF-8?q?=5FPDF=5FSIREN=20et=20FAC=5FPDF=5FSIRET=20Cela=20=E9limine=20de?= =?UTF-8?q?s=20variables=20en=20doublons.=20Trad:=20Traductions=20de=20la?= =?UTF-8?q?=20page=20configuration=20-=20g=E9n=E9ral?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/admin/index.php | 81 ++++++++++++++++++++++++++++++------------ 1 file changed, 59 insertions(+), 22 deletions(-) diff --git a/htdocs/admin/index.php b/htdocs/admin/index.php index 7f59dc5eda3..eeb1db07ccb 100644 --- a/htdocs/admin/index.php +++ b/htdocs/admin/index.php @@ -1,6 +1,6 @@ - * Copyright (C) 2004 Laurent Destailleur + * Copyright (C) 2004-2005 Laurent Destailleur * * 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 @@ -20,7 +20,8 @@ * $Source$ */ -/*! \file htdocs/admin/index.php +/** + \file htdocs/admin/index.php \brief Page d'accueil de l'espace administration/configuration \version $Revision$ */ @@ -28,6 +29,7 @@ require("./pre.inc.php"); $langs->load("admin"); +$langs->load("companies"); if (!$user->admin) accessforbidden(); @@ -37,11 +39,13 @@ if ($_POST["action"] == 'update') { dolibarr_set_const($db, "MAIN_INFO_SOCIETE_NOM",$_POST["nom"]); dolibarr_set_const($db, "MAIN_INFO_SOCIETE_PAYS",$_POST["pays_id"]); - dolibarr_set_const($db, "MAIN_INFO_TVAINTRA",$_POST["tva"]); + dolibarr_set_const($db, "MAIN_MONNAIE",$_POST["currency"]); dolibarr_set_const($db, "MAIN_INFO_CAPITAL",$_POST["capital"]); - dolibarr_set_const($db, "MAIN_INFO_SIREN",$_POST["siren"]); + dolibarr_set_const($db, "MAIN_INFO_SIRET",$_POST["siret"]); + dolibarr_set_const($db, "MAIN_INFO_SIREN",$_POST["siren"]); dolibarr_set_const($db, "MAIN_INFO_APE",$_POST["ape"]); + dolibarr_set_const($db, "MAIN_INFO_TVAINTRA",$_POST["tva"]); Header("Location: index.php"); } @@ -57,57 +61,90 @@ print "
\n"; if ($_GET["action"] == 'edit') { + /* + * Edition des paramètres + */ print '
'; print ''; print ''; - print ''; + print ''; - print ''; - print ''; - print ''; + print ''; - print ''; - print '
Informations sur la société ou association
'.$langs->trans("CompanyInfo").'
Nom de la société/association'; + print '
'.$langs->trans("CompanyName").''; print '
Pays de la société'; + print '
'.$langs->trans("Country").''; $form->select_pays(MAIN_INFO_SOCIETE_PAYS); print '
Numéro de TVA intracommunautaire'; - print '
'.$langs->trans("CompanyCurrency").''; + print '
Capital'; + print '
'.$langs->trans("Capital").''; print '
Identifiant professionnel (SIREN,SIRET,...)'; + print '
'; + + print '
'; + + print ''; + print ''; + + print ''; + + print ''; - print ''; - print ''; - print '
'.$langs->trans("CompanyIds").''.$langs->trans("Value").'
'.$langs->trans("ProfIdSiret").''; + print '
'.$langs->trans("ProfIdSiren").''; print '
Code de l\'activité économique'; + print '
'.$langs->trans("ProfIdApe").''; print '
'; - print '
'; + print ''.$langs->trans("TVAIntra").''; + print ''; + + print ''; + + print '
'; + + print ''; } else { + /* + * Affichage des paramètres + */ print ''; - print ''; - print ''; + print ''; - print ''; + + print ''; - print ''; + print ''; - print ''; - print '
Informations sur la société/association'.$langs->trans("Value").'
Nom de la société/association' . MAIN_INFO_SOCIETE_NOM . '
'.$langs->trans("CompanyInfo").''.$langs->trans("Value").'
Pays de la société'; + print '
'.$langs->trans("CompanyName").'' . MAIN_INFO_SOCIETE_NOM . '
'.$langs->trans("Country").''; print $form->pays_name(MAIN_INFO_SOCIETE_PAYS); print '
Numéro de TVA intracommunautaire' . MAIN_INFO_TVAINTRA . '
'.$langs->trans("CompanyCurrency").'' . MAIN_MONNAIE . '
Capital'; + print '
'.$langs->trans("Capital").''; print MAIN_INFO_CAPITAL . '
Identifiant professionnel (SIREN,...)'; + print '
'; + + print '
'; + + print ''; + print ''; + + print ''; + + print ''; - print ''; + print ''; print '
'.$langs->trans("CompanyIds").''.$langs->trans("Value").'
'.$langs->trans("ProfIdSiret").''; + print MAIN_INFO_SIRET . '
'.$langs->trans("ProfIdSiren").''; print MAIN_INFO_SIREN . '
Code de l\'activité économique'; + print '
'.$langs->trans("ProfIdApe").''; print MAIN_INFO_APE . '
'.$langs->trans("TVAIntra").'' . MAIN_INFO_TVAINTRA . '

';