Exclude only replaced (duplicated) invoices.
This commit is contained in:
parent
ccb14879e8
commit
957318f9d2
@ -71,7 +71,7 @@ class FactureStats extends Stats
|
|||||||
$this->socid = $socid;
|
$this->socid = $socid;
|
||||||
$this->where = " fk_statut > 0";
|
$this->where = " fk_statut > 0";
|
||||||
$this->where.= " AND entity = ".$conf->entity;
|
$this->where.= " AND entity = ".$conf->entity;
|
||||||
if ($mode == 'customer') $this->where.=" AND fk_statut != 3"; // Exclude replaced invoices
|
if ($mode == 'customer') $this->where.=" AND (fk_statut != 3 OR close_code != 'replaced')"; // Exclude replaced invoices as they are duplicated (we count closed invoices for other reasons)
|
||||||
if ($this->socid)
|
if ($this->socid)
|
||||||
{
|
{
|
||||||
$this->where.=" AND fk_soc = ".$this->socid;
|
$this->where.=" AND fk_soc = ".$this->socid;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user