[ Index ]
 

Code source de Dolibarr 2.0.1

Accédez au Source d'autres logiciels libres

Classes | Fonctions | Variables | Constantes | Tables

title

Body

[fermer]

/htdocs/fourn/facture/ -> pre.inc.php (source)

   1  <?php
   2  /* Copyright (C) 2001-2005 Rodolphe Quiedeville <rodolphe@quiedeville.org>
   3   * Copyright (C) 2004-2005 Laurent Destailleur  <eldy@users.sourceforge.net>
   4   *
   5   * This program is free software; you can redistribute it and/or modify
   6   * it under the terms of the GNU General Public License as published by
   7   * the Free Software Foundation; either version 2 of the License, or
   8   * (at your option) any later version.
   9   *
  10   * This program is distributed in the hope that it will be useful,
  11   * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12   * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  13   * GNU General Public License for more details.
  14   *
  15   * You should have received a copy of the GNU General Public License
  16   * along with this program; if not, write to the Free Software
  17   * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
  18   *
  19   * $Id: pre.inc.php,v 1.19 2005/07/23 14:48:59 hregis Exp $
  20   * $Source: /cvsroot/dolibarr/dolibarr/htdocs/fourn/facture/pre.inc.php,v $
  21   *
  22   */
  23  
  24  /**
  25          \file       htdocs/fourn/facture/pre.inc.php
  26          \ingroup    fournisseur,facture
  27          \brief      Fichier gestionnaire du menu factures fournisseurs
  28  */
  29  
  30  require ("../../main.inc.php");
  31  require_once  DOL_DOCUMENT_ROOT."/fourn/fournisseur.class.php";
  32  require_once DOL_DOCUMENT_ROOT."/fourn/fournisseur.facture.class.php";
  33  $user->getrights('fournisseur');
  34  
  35  function llxHeader($head = "", $title = "", $addons='') {
  36    global $user, $conf, $langs;
  37  
  38    $langs->load("suppliers");
  39    $langs->load("propal");
  40  
  41    top_menu($head, $title);
  42  
  43    $menu = new Menu();
  44  
  45  
  46    if (is_array($addons))
  47      {
  48        //$menu->add($url, $libelle);
  49  
  50        $menu->add($addons[0][0], $addons[0][1]);
  51      }
  52  
  53  
  54    if ($conf->fournisseur->enabled) 
  55      {
  56          if ($user->rights->societe->lire)
  57          {
  58          $menu->add(DOL_URL_ROOT."/fourn/index.php", $langs->trans("Suppliers"));
  59        }
  60  
  61          // Sécurité accés client
  62          if ($user->societe_id == 0 && $user->rights->societe->creer) 
  63          {
  64            $menu->add_submenu(DOL_URL_ROOT."/soc.php?action=create&type=f",$langs->trans("NewSupplier"));
  65          }
  66      }
  67  
  68    if ($conf->societe->enabled)
  69      {
  70          if ($user->rights->societe->lire)
  71          {
  72           $menu->add_submenu(DOL_URL_ROOT."/fourn/contact.php",$langs->trans("Contacts"));
  73        }
  74      }
  75    
  76  
  77    $langs->load("bills");
  78    if ($user->rights->fournisseur->facture->lire)
  79    {
  80        $menu->add(DOL_URL_ROOT."/fourn/facture/index.php", $langs->trans("Bills"));
  81    }
  82    
  83  
  84    if ($user->rights->fournisseur->facture->creer)
  85      {
  86        $menu->add_submenu(DOL_URL_ROOT."/fourn/facture/fiche.php?action=create",$langs->trans("NewBill"));
  87      }
  88    if ($user->rights->fournisseur->facture->lire)
  89    {
  90        $menu->add_submenu(DOL_URL_ROOT."/fourn/facture/paiement.php", $langs->trans("Payments"));
  91    }
  92  
  93    
  94    $langs->load("orders");
  95    if ($user->rights->fournisseur->commande->lire)
  96    {
  97        $menu->add(DOL_URL_ROOT."/fourn/commande/",$langs->trans("Orders"));
  98    }
  99  
 100  
 101    if ($conf->produit->enabled || $conf->service->enabled)
 102    {
 103        $menu->add(DOL_URL_ROOT."/product/liste.php?type=0", $langs->trans("Products"));
 104    }
 105    
 106    left_menu($menu->liste);
 107  }
 108  
 109  
 110  ?>


Généré le : Mon Nov 26 12:29:37 2007 par Balluche grâce à PHPXref 0.7
  Clicky Web Analytics