Merge pull request #5903 from atm-gauthier/FIX_thirdparty_margin
FIX : margin tab on customer card must filter on current entity invoices
This commit is contained in:
commit
e4da87d31c
@ -152,7 +152,7 @@ if ($socid > 0)
|
||||
$sql.= ", ".MAIN_DB_PREFIX."facturedet as d";
|
||||
$sql.= " WHERE f.fk_soc = s.rowid";
|
||||
$sql.= " AND f.fk_statut > 0";
|
||||
$sql.= " AND s.entity = ".$conf->entity;
|
||||
$sql.= " AND f.entity = ".$conf->entity;
|
||||
$sql.= " AND d.fk_facture = f.rowid";
|
||||
$sql.= " AND f.fk_soc = $socid";
|
||||
$sql.= " AND d.buy_price_ht IS NOT NULL";
|
||||
|
||||
Loading…
Reference in New Issue
Block a user