Update customerMargins.php

This commit is contained in:
Pierre Ardoin 2019-11-03 22:45:50 +01:00 committed by GitHub
parent abc7198db4
commit d2b7961e87
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -220,7 +220,7 @@ if ($socid > 0) $sql.= ' AND s.rowid = '.$socid;
if (!$user->rights->societe->client->voir && ! $socid) $sql.= " AND s.rowid = sc.fk_soc AND sc.fk_user = " .$user->id;
$sql.= " AND f.fk_statut NOT IN (" . implode(', ', $invoice_status_except_list) . ")";
$sql.= ' AND s.entity IN ('.getEntity('societe').')';
$sql.= ' AND f.entity IN ('.getEntity('').')';
$sql.= ' AND f.entity IN ('.getEntity('invoice').')';
$sql.= " AND d.fk_facture = f.rowid";
$sql.= " AND (d.product_type = 0 OR d.product_type = 1)";
if(! empty($TSelectedProducts)) {