From 24fff5b451550a5c12157a7637071db8b5928f54 Mon Sep 17 00:00:00 2001 From: Laurent Destailleur Date: Fri, 8 Apr 2005 20:18:55 +0000 Subject: [PATCH] =?UTF-8?q?Fix:=20Manque=20entr=E9e=20dans=20menu?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- htdocs/fourn/facture/pre.inc.php | 26 +++++++++++++++++++------- htdocs/fourn/pre.inc.php | 9 +++++---- 2 files changed, 24 insertions(+), 11 deletions(-) diff --git a/htdocs/fourn/facture/pre.inc.php b/htdocs/fourn/facture/pre.inc.php index 8f755a84a70..fa54bd3c47b 100644 --- a/htdocs/fourn/facture/pre.inc.php +++ b/htdocs/fourn/facture/pre.inc.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 @@ -21,10 +21,10 @@ * */ -/*! - \file htdocs/fourn/facture/pre.inc.php - \ingroup fournisseur,facture - \brief Fichier gestionnaire du menu factures fournisseurs +/** + \file htdocs/fourn/facture/pre.inc.php + \ingroup fournisseur,facture + \brief Fichier gestionnaire du menu factures fournisseurs */ require("../../main.inc.php"); @@ -48,9 +48,21 @@ function llxHeader($head = "", $title = "", $addons='') { } - $menu->add(DOL_URL_ROOT."/fourn/index.php", $langs->trans("Suppliers")); - $menu->add_submenu(DOL_URL_ROOT."/fourn/contact.php",$langs->trans("Contacts")); + if ($conf->fournisseur->enabled) + { + $menu->add(DOL_URL_ROOT."/fourn/index.php", $langs->trans("Suppliers")); + // Sécurité accés client + if ($user->societe_id == 0) + { + $menu->add_submenu(DOL_URL_ROOT."/soc.php?action=create&type=f",$langs->trans("NewSupplier")); + } + } + + if ($conf->societe->enabled) + { + $menu->add_submenu(DOL_URL_ROOT."/fourn/contact.php",$langs->trans("Contacts")); + } $langs->load("bills"); diff --git a/htdocs/fourn/pre.inc.php b/htdocs/fourn/pre.inc.php index 6c22540f3f3..a112284aa67 100644 --- a/htdocs/fourn/pre.inc.php +++ b/htdocs/fourn/pre.inc.php @@ -1,5 +1,6 @@ + * Copyright (C) 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,10 +21,10 @@ * */ -/*! - \file htdocs/fourn/pre.inc.php - \ingroup fournisseur,facture - \brief Fichier gestionnaire du menu fournisseurs +/** + \file htdocs/fourn/pre.inc.php + \ingroup fournisseur,facture + \brief Fichier gestionnaire du menu fournisseurs */ require("../main.inc.php");