Update box_graph_orders_permonth.php

This commit is contained in:
Frédéric FRANCE 2019-11-01 15:52:13 +01:00 committed by GitHub
parent 44c8cd9d23
commit 931f2b809d
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -135,7 +135,8 @@ class box_graph_orders_permonth extends ModeleBoxes
$data1 = $stats->getNbByMonthWithPrevYear($endyear, $startyear, (GETPOST('action', 'aZ09')==$refreshaction?-1:(3600*24)), ($WIDTH<300?2:0), $startmonth); $data1 = $stats->getNbByMonthWithPrevYear($endyear, $startyear, (GETPOST('action', 'aZ09')==$refreshaction?-1:(3600*24)), ($WIDTH<300?2:0), $startmonth);
$filenamenb = $dir."/".$prefix."ordersnbinyear-".$endyear.".png"; $filenamenb = $dir."/".$prefix."ordersnbinyear-".$endyear.".png";
if ($mode == 'customer') $fileurlnb = DOL_URL_ROOT.'/viewimage.php?modulepart=orderstats&amp;file=ordersnbinyear-'.$endyear.'.png'; // default value for customer mode
$fileurlnb = DOL_URL_ROOT.'/viewimage.php?modulepart=orderstats&amp;file=ordersnbinyear-'.$endyear.'.png';
if ($mode == 'supplier') $fileurlnb = DOL_URL_ROOT.'/viewimage.php?modulepart=orderstatssupplier&amp;file=ordersnbinyear-'.$endyear.'.png'; if ($mode == 'supplier') $fileurlnb = DOL_URL_ROOT.'/viewimage.php?modulepart=orderstatssupplier&amp;file=ordersnbinyear-'.$endyear.'.png';
$px1 = new DolGraph(); $px1 = new DolGraph();
@ -144,7 +145,8 @@ class box_graph_orders_permonth extends ModeleBoxes
{ {
$px1->SetData($data1); $px1->SetData($data1);
unset($data1); unset($data1);
$i=$startyear;$legend=array(); $i=$startyear;
$legend=array();
while ($i <= $endyear) while ($i <= $endyear)
{ {
if ($startmonth != 1) if ($startmonth != 1)