2
0
forked from Wavyzz/dolibarr

New: getEntity function use true $shared value by default

This commit is contained in:
Regis Houssin
2017-05-30 18:50:54 +02:00
parent d9cdad6a77
commit 5c5663c5ae
237 changed files with 456 additions and 454 deletions

View File

@@ -128,7 +128,7 @@ class CommandeApi extends DolibarrApi
//if ($mode == 1) $sql.= " AND s.client IN (1, 3)";
//if ($mode == 2) $sql.= " AND s.client IN (2, 3)";
$sql.= ' WHERE s.entity IN ('.getEntity('commande', 1).')';
$sql.= ' WHERE s.entity IN ('.getEntity('commande').')';
if ((!DolibarrApiAccess::$user->rights->societe->client->voir && !$socid) || $search_sale > 0) $sql.= " AND s.fk_soc = sc.fk_soc";
if ($socid) $sql.= " AND s.fk_soc = ".$socid;
if ($search_sale > 0) $sql.= " AND s.rowid = sc.fk_soc"; // Join for the needed table to filter by sale