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 '
'; } }