From 5f0dea54b4bd2d339ffa65264dd128124bdad31c Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Thu, 11 Aug 2005 20:22:38 +0000 Subject: [PATCH] =?UTF-8?q?Bouton=20ajouter=20projet=20=E0=20soci=E9t=E9?= =?UTF-8?q?=20sur=20onglet=20soci=E9t=E9.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/soc.php | 42 +++++++++++++++++++++++++----------------- 1 file changed, 25 insertions(+), 17 deletions(-) diff --git a/htdocs/soc.php b/htdocs/soc.php index b78ccb9a1b6..2ef3c23f5f7 100644 --- a/htdocs/soc.php +++ b/htdocs/soc.php @@ -24,10 +24,10 @@ */ /** - \file htdocs/soc.php - \ingroup societe - \brief Onglet societe d'une societe - \version $Revision$ + \file htdocs/soc.php + \ingroup societe + \brief Onglet societe d'une societe + \version $Revision$ */ require("pre.inc.php"); @@ -644,22 +644,30 @@ else */ if ($_GET["action"] == '') { - print '
'; + print '
'; - if ($user->rights->societe->creer) + if ($user->rights->societe->creer) { - print ''.$langs->trans("Edit").''; - - print ''.$langs->trans("AddContact").''; - - } - - if ($user->rights->societe->supprimer) - { - print ''.$langs->trans("Delete").''; - + print ''.$langs->trans("Edit").''; } - print '
'; + + if ($conf->projet->enabled && $user->rights->projet->creer) + { + $langs->load("projects"); + print ''.$langs->trans("AddProject").''; + } + + if ($user->rights->societe->creer) + { + print ''.$langs->trans("AddContact").''; + } + + if ($user->rights->societe->supprimer) + { + print ''.$langs->trans("Delete").''; + } + + print '
'; } }