Update list.php

This commit is contained in:
UT from dolibit 2022-09-06 21:22:52 +02:00 committed by GitHub
parent 8ee927f593
commit 17a4e20abb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -22,17 +22,23 @@
/** /**
* \file htdocs/fourn/product/list.php * \file htdocs/fourn/product/list.php
* \ingroup produit * \ingroup product
* \brief Page to list supplier products and services * \brief Page to list supplier products and services
*/ */
// Load Dolibarr environment
require '../../main.inc.php'; require '../../main.inc.php';
require_once DOL_DOCUMENT_ROOT .'/product/class/product.class.php'; require_once DOL_DOCUMENT_ROOT .'/product/class/product.class.php';
require_once DOL_DOCUMENT_ROOT .'/societe/class/societe.class.php'; require_once DOL_DOCUMENT_ROOT .'/societe/class/societe.class.php';
require_once DOL_DOCUMENT_ROOT .'/fourn/class/fournisseur.class.php'; require_once DOL_DOCUMENT_ROOT .'/fourn/class/fournisseur.class.php';
$langs->loadLangs(array("products", "suppliers"));
// Load translation files required by the page
$langs->loadLangs(array('products', 'suppliers'));
// Get Parameters
$sref = GETPOST('sref', 'alphanohtml'); $sref = GETPOST('sref', 'alphanohtml');
$sRefSupplier = GETPOST('srefsupplier'); $sRefSupplier = GETPOST('srefsupplier');
$snom = GETPOST('snom', 'alphanohtml'); $snom = GETPOST('snom', 'alphanohtml');
@ -72,6 +78,7 @@ if (empty($user->rights->produit->lire) && empty($user->rights->service->lire))
accessforbidden(); accessforbidden();
} }
// Permissions
$permissiontoadd = ($user->hasRight('produit', 'lire') || $user->hasRight('service', 'lire')); $permissiontoadd = ($user->hasRight('produit', 'lire') || $user->hasRight('service', 'lire'));
@ -111,6 +118,7 @@ if (empty($reshook)) {
} }
} }
/* /*
* View * View
*/ */