Fix in coloring negative amounts

This commit is contained in:
Laurent Destailleur 2010-08-21 17:45:44 +00:00
parent ea8d8a1e28
commit 3c2673e528

View File

@ -472,8 +472,6 @@ if ($account || $_GET["ref"])
$result = $db->query($sql); $result = $db->query($sql);
if ($result) if ($result)
{ {
$total = 0;
$now=dol_now('tzserver'); $now=dol_now('tzserver');
$nows=dol_date('Ymd',$now); $nows=dol_date('Ymd',$now);
@ -488,7 +486,7 @@ if ($account || $_GET["ref"])
while ($i < $num) while ($i < $num)
{ {
$objp = $db->fetch_object($result); $objp = $db->fetch_object($result);
$total = $total + $objp->amount; $total = price2num($total + $objp->amount,'MT');
if ($i >= ($nbline - $viewline)) if ($i >= ($nbline - $viewline))
{ {
$var=!$var; $var=!$var;