Fix rounding
This commit is contained in:
parent
5c6c708531
commit
3bc1f90589
@ -2666,7 +2666,7 @@ class Product extends CommonObject
|
|||||||
$obj = $this->db->fetch_object($result);
|
$obj = $this->db->fetch_object($result);
|
||||||
$this->stats_mo['customers_'.$role] = $obj->nb_customers ? $obj->nb_customers : 0;
|
$this->stats_mo['customers_'.$role] = $obj->nb_customers ? $obj->nb_customers : 0;
|
||||||
$this->stats_mo['nb_'.$role] = $obj->nb ? $obj->nb : 0;
|
$this->stats_mo['nb_'.$role] = $obj->nb ? $obj->nb : 0;
|
||||||
$this->stats_mo['qty_'.$role] = $obj->qty ? $obj->qty : 0;
|
$this->stats_mo['qty_'.$role] = $obj->qty ? price2num($obj->qty, 'MS') : 0; // qty may be a float due to the SUM()
|
||||||
} else {
|
} else {
|
||||||
$this->error = $this->db->error();
|
$this->error = $this->db->error();
|
||||||
$error++;
|
$error++;
|
||||||
|
|||||||
@ -1,6 +1,6 @@
|
|||||||
<?php
|
<?php
|
||||||
/* Copyright (C) 2003-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
/* Copyright (C) 2003-2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||||
* Copyright (C) 2004-2009 Laurent Destailleur <eldy@users.sourceforge.net>
|
* Copyright (C) 2004-2021 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||||
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@inodbox.com>
|
* Copyright (C) 2005-2009 Regis Houssin <regis.houssin@inodbox.com>
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify
|
* This program is free software; you can redistribute it and/or modify
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user