New: Super clean of permissions checks
This commit is contained in:
parent
e9aed4f921
commit
646a6307f0
@ -2,7 +2,7 @@
|
||||
/* Copyright (C) 2001-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
* Copyright (C) 2005 Brice Davoleau <brice.davoleau@gmail.com>
|
||||
* Copyright (C) 2005-2007 Regis Houssin <regis@dolibarr.fr>
|
||||
* Copyright (C) 2006-2007 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2006-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2007 Patrick Raguin <patrick.raguin@gmail.com>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
@ -36,20 +36,17 @@ $mesg=isset($_GET["mesg"])?'<div class="ok">'.$_GET["mesg"].'</div>':'';
|
||||
|
||||
if ($_REQUEST["socid"])
|
||||
{
|
||||
if ($_REQUEST["typeid"] == 1) $type = 'fournisseur';
|
||||
if ($_REQUEST["typeid"] == 2) $type = 'societe';
|
||||
if ($_REQUEST["typeid"] == 1) { $type = 'fournisseur'; $socid = isset($_REQUEST["socid"])?$_REQUEST["socid"]:''; }
|
||||
if ($_REQUEST["typeid"] == 2) { $type = 'societe'; $socid = isset($_REQUEST["socid"])?$_REQUEST["socid"]:''; }
|
||||
$objectid = isset($_REQUEST["socid"])?$_REQUEST["socid"]:'';
|
||||
}
|
||||
else if ($_REQUEST["id"] || $_REQUEST["ref"])
|
||||
{
|
||||
$type = 'produit';
|
||||
}
|
||||
else
|
||||
{
|
||||
accessforbidden();
|
||||
}
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, $type, $objectid);
|
||||
|
||||
|
||||
|
||||
@ -40,6 +40,7 @@ $page = isset($_GET["page"])?$_GET["page"]:$_POST["page"];
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
if ($page == -1) { $page = 0 ; }
|
||||
|
||||
@ -39,6 +39,7 @@ $socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if (! $socid && ($_REQUEST["action"] != 'create' && $_REQUEST["action"] != 'add' && $_REQUEST["action"] != 'update')) accessforbidden();
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe', $socid);
|
||||
|
||||
|
||||
|
||||
@ -28,6 +28,7 @@ require("./pre.inc.php");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
$page=$_GET["page"];
|
||||
|
||||
@ -42,6 +42,7 @@ $type=$_GET["type"];
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -43,6 +43,7 @@ if ($conf->fichinter->enabled) $langs->load("interventions");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
$sortorder=$_GET["sortorder"];
|
||||
|
||||
@ -64,6 +64,7 @@ else if (isset($_GET["propalid"]) && $_GET["propalid"] > 0)
|
||||
$module='propale';
|
||||
$dbtable='propal';
|
||||
}
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, $module, $objectid, $dbtable);
|
||||
|
||||
// Nombre de ligne pour choix de produit/service predefinis
|
||||
|
||||
@ -30,6 +30,7 @@ include_once(DOL_DOCUMENT_ROOT."/propal.class.php");
|
||||
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
|
||||
|
||||
// Security cehck
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'propale', $propalid, 'propal');
|
||||
|
||||
|
||||
|
||||
@ -40,6 +40,7 @@ $langs->load('compta');
|
||||
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'propale', $propalid, 'propal');
|
||||
|
||||
|
||||
|
||||
@ -37,6 +37,7 @@ $langs->load("companies");
|
||||
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'propale', $propalid, 'propal');
|
||||
|
||||
|
||||
|
||||
@ -39,6 +39,7 @@ $action=empty($_GET['action']) ? (empty($_POST['action']) ? '' : $_POST['action'
|
||||
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'propale', $propalid, 'propal');
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load('compta');
|
||||
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'propale', $propalid, 'propal');
|
||||
|
||||
|
||||
|
||||
@ -37,6 +37,7 @@ $langs->load('bills');
|
||||
$propalid = isset($_GET["propalid"])?$_GET["propalid"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'propale', $propalid, 'propal');
|
||||
|
||||
|
||||
|
||||
@ -37,6 +37,7 @@ $langs->load('propal');
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("propal");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
$socname=isset($_GET["socname"])?$_GET["socname"]:$_POST["socname"];
|
||||
|
||||
@ -37,6 +37,7 @@ $langs->load("companies");
|
||||
$commandeid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'commande', $commandeid);
|
||||
|
||||
|
||||
|
||||
@ -42,6 +42,7 @@ $sall=isset($_GET['sall'])?$_GET['sall']:$_POST['sall'];
|
||||
|
||||
// Security check
|
||||
$orderid = isset($_GET["orderid"])?$_GET["orderid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'commande', $orderid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -44,6 +44,7 @@ $offset = $limit * $_GET["page"] ;
|
||||
|
||||
// Security check
|
||||
$orderid = isset($_GET["orderid"])?$_GET["orderid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'commande',$orderid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -29,6 +29,7 @@ $langs->load("trips");
|
||||
|
||||
// Security check
|
||||
$id=isset($_GET["id"])?$_GET["id"]:$_POST["id"];
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'deplacement', $id,'',1);
|
||||
|
||||
|
||||
|
||||
@ -33,6 +33,7 @@ $langs->load("users");
|
||||
$langs->load("trips");
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'deplacement','','',1);
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load("companies");
|
||||
$facid = isset($_GET["facid"])?$_GET["facid"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'facture', $facid);
|
||||
|
||||
|
||||
|
||||
@ -36,6 +36,7 @@ $langs->load("bills");
|
||||
|
||||
// Security check
|
||||
$facid = isset($_GET["facid"])?$_GET["facid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'facture',$facid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ if ($conf->projet->enabled) $langs->load("projects");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load('banks');
|
||||
$langs->load('companies');
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'banque', '','',0);
|
||||
|
||||
$mesg='';
|
||||
|
||||
@ -31,6 +31,7 @@ require_once(DOL_DOCUMENT_ROOT.'/compta/bank/account.class.php');
|
||||
$langs->load("banks");
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'banque', '','',1);
|
||||
|
||||
|
||||
|
||||
@ -31,6 +31,7 @@ require_once(DOL_DOCUMENT_ROOT.'/compta/bank/account.class.php');
|
||||
$langs->load("bills");
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'banque', '','',1);
|
||||
|
||||
$page=$_GET["page"];
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load("bills");
|
||||
|
||||
// Security check
|
||||
$facid = isset($_GET["facid"])?$_GET["facid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'facture',$facid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("widthdrawals");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'prelevement','','',1);
|
||||
|
||||
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("withdrawals");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'prelevement','','',1);
|
||||
|
||||
|
||||
|
||||
@ -64,6 +64,7 @@ else if (! empty($_GET["propalid"]))
|
||||
}
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, $module, $objectid, $dbtable);
|
||||
|
||||
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("companies");
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact',$contactid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -40,6 +40,7 @@ $socid=$_GET["socid"]?$_GET["socid"]:$_POST["socid"];
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact', $contactid,'socpeople',0);
|
||||
|
||||
|
||||
|
||||
@ -33,6 +33,7 @@ $langs->load("suppliers");
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact', $contactid,'',1);
|
||||
|
||||
$search_nom=isset($_GET["search_nom"])?$_GET["search_nom"]:$_POST["search_nom"];
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("companies");
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact',$contactid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load("admin");
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact',$contactid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -32,6 +32,7 @@ $langs->load("companies");
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact',$contactid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -36,6 +36,7 @@ $langs->load("companies");
|
||||
$contratid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contrat', $contratid);
|
||||
|
||||
|
||||
|
||||
@ -37,6 +37,7 @@ $langs->load("bills");
|
||||
$langs->load("products");
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result=restrictedArea($user,'contrat',$contratid,'contrat');
|
||||
|
||||
|
||||
|
||||
@ -40,6 +40,7 @@ $statut=isset($_GET["statut"])?$_GET["statut"]:1;
|
||||
|
||||
// Security check
|
||||
$contratid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contrat',$contratid,'',1);
|
||||
|
||||
$staticcontrat=new Contrat($db);
|
||||
|
||||
@ -14,15 +14,13 @@
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/**
|
||||
\file htdocs/contrat/info.php
|
||||
\ingroup contrat
|
||||
\brief Page des informations d'un contrat
|
||||
\version $Revision$
|
||||
\version $Id$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
@ -33,6 +31,7 @@ $langs->load("contracts");
|
||||
|
||||
// Security check
|
||||
$contratid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contrat',$contratid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -49,6 +49,7 @@ if (! $sortorder) $sortorder="DESC";
|
||||
|
||||
// Security check
|
||||
$contratid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contrat', $contratid,'',1);
|
||||
|
||||
$staticcontrat=new Contrat($db);
|
||||
|
||||
@ -38,6 +38,7 @@ $langs->load("contracts");
|
||||
|
||||
// Security check
|
||||
$contactid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contact',$contactid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -50,6 +50,7 @@ $socid=$_GET["socid"];
|
||||
|
||||
// Security check
|
||||
$contratid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'contrat',$contratid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -34,13 +34,14 @@ $langs->load('other');
|
||||
|
||||
$mesg = "";
|
||||
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
$sortorder=$_GET["sortorder"];
|
||||
$sortfield=$_GET["sortfield"];
|
||||
if (! $sortorder) $sortorder="ASC";
|
||||
if (! $sortfield) $sortfield="name";
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe', $socid);
|
||||
|
||||
/*
|
||||
|
||||
@ -16,15 +16,13 @@
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* $Id$
|
||||
* $Source$
|
||||
*/
|
||||
|
||||
/**
|
||||
\file htdocs/expedition/liste.php
|
||||
\ingroup expedition
|
||||
\brief Page de la liste des expéditions/livraisons
|
||||
\version $Id$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
@ -33,6 +31,7 @@ $langs->load('companies');
|
||||
|
||||
// Security check
|
||||
$expeditionid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'expedition',$expeditionid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -36,6 +36,7 @@ $langs->load("companies");
|
||||
$fichinterid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'ficheinter', $fichinterid, 'fichinter');
|
||||
|
||||
|
||||
|
||||
@ -49,6 +49,7 @@ if ($conf->use_javascript_ajax && $conf->global->COMPANY_USE_SEARCH_TO_SELECT &&
|
||||
}
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'ficheinter', $fichinterid, 'fichinter');
|
||||
|
||||
|
||||
|
||||
@ -39,6 +39,7 @@ $page=$_GET["page"]?$_GET["page"]:$_POST["page"];
|
||||
|
||||
// Security check
|
||||
$fichinterid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'ficheinter', $fichinterid,'',1);
|
||||
|
||||
if (! $sortorder) $sortorder="DESC";
|
||||
|
||||
@ -32,6 +32,7 @@ $langs->load('companies');
|
||||
$fichinterid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'ficheinter', $fichinterid, 'fichinter');
|
||||
|
||||
|
||||
|
||||
@ -32,6 +32,7 @@ $langs->load('companies');
|
||||
$fichinterid = isset($_GET["id"])?$_GET["id"]:'';
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'ficheinter', $fichinterid, 'fichinter');
|
||||
|
||||
|
||||
|
||||
@ -29,6 +29,7 @@ require_once(DOL_DOCUMENT_ROOT."/contact.class.php");
|
||||
|
||||
// Security check
|
||||
$orderid = isset($_GET["orderid"])?$_GET["orderid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'commande_fournisseur', $orderid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ $sortfield = $_GET["sortfield"];
|
||||
|
||||
// Security check
|
||||
$orderid = isset($_GET["orderid"])?$_GET["orderid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'commande_fournisseur', $orderid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -38,6 +38,7 @@ $langs->load('commercial');
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -38,6 +38,7 @@ $langs->load('commercial');
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load("companies");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -46,6 +46,7 @@ $langs->load("companies");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
|
||||
|
||||
@ -42,6 +42,7 @@ $search_ville = isset($_GET["search_ville"])?$_GET["search_ville"]:'';
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe',$socid,'',1);
|
||||
|
||||
if ($page == -1) { $page = 0 ; }
|
||||
|
||||
@ -42,6 +42,7 @@ if ($_GET["id"]) { $projetid=$_GET["id"]; }
|
||||
if ($projetid == '') accessforbidden();
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'projet', $projetid);
|
||||
|
||||
|
||||
|
||||
@ -42,6 +42,7 @@ if ($_GET["id"]) { $projetid=$_GET["id"]; }
|
||||
if ($projetid == '') accessforbidden();
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'projet', $projetid);
|
||||
|
||||
|
||||
|
||||
@ -37,6 +37,7 @@ if ($_GET["id"]) { $projetid=$_GET["id"]; }
|
||||
if ($projetid == '' && ($_GET['action'] != "create" && $_POST['action'] != "add" && $_POST["action"] != "update" && !$_POST["cancel"])) accessforbidden();
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'projet', $projetid);
|
||||
|
||||
|
||||
|
||||
@ -42,6 +42,7 @@ if ($_GET["id"]) { $projetid=$_GET["id"]; }
|
||||
if ($projetid == '') accessforbidden();
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'projet', $projetid);
|
||||
|
||||
|
||||
|
||||
@ -37,6 +37,7 @@ if ($_GET["id"]) { $projetid=$_GET["id"]; }
|
||||
if ($projetid == '') accessforbidden();
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'projet', $projetid);
|
||||
|
||||
|
||||
|
||||
@ -34,9 +34,9 @@ $langs->load("companies");
|
||||
$langs->load("commercial");
|
||||
$langs->load("bills");
|
||||
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe', $socid);
|
||||
|
||||
// Initialisation de l'objet Societe
|
||||
|
||||
@ -33,6 +33,7 @@ $langs->load("customers");
|
||||
$langs->load("suppliers");
|
||||
|
||||
// Security check
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe','','',1);
|
||||
|
||||
$search_nom=isset($_GET["search_nom"])?$_GET["search_nom"]:$_POST["search_nom"];
|
||||
|
||||
@ -35,6 +35,7 @@ $langs->load("banks");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe','','',1);
|
||||
|
||||
|
||||
|
||||
@ -32,6 +32,7 @@ $langs->load("other");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe','','',1);
|
||||
|
||||
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("banks");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe','','',1);
|
||||
|
||||
|
||||
|
||||
@ -33,6 +33,7 @@ $langs->load("mails");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe','','',1);
|
||||
|
||||
$sortorder=$_GET["sortorder"];
|
||||
|
||||
@ -34,6 +34,7 @@ $langs->load("banks");
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:'';
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe','','',1);
|
||||
|
||||
$soc = new Societe($db);
|
||||
|
||||
@ -32,10 +32,9 @@ $action = isset($_GET["action"])?$_GET["action"]:$_POST["action"];
|
||||
|
||||
$langs->load("companies");
|
||||
|
||||
// Protection quand utilisateur externe
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:$_POST["socid"];
|
||||
|
||||
// Security check
|
||||
$socid = isset($_GET["socid"])?$_GET["socid"]:$_POST["socid"];
|
||||
if ($user->societe_id) $socid=$user->societe_id;
|
||||
$result = restrictedArea($user, 'societe', $socid);
|
||||
|
||||
if ($_POST["action"] == 'add')
|
||||
|
||||
Loading…
Reference in New Issue
Block a user