Fix box activity again
This commit is contained in:
parent
f76b675e09
commit
eaee8ee586
@ -77,7 +77,6 @@ class box_activity extends ModeleBoxes
|
|||||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
include_once DOL_DOCUMENT_ROOT.'/core/lib/date.lib.php';
|
||||||
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
include_once DOL_DOCUMENT_ROOT.'/core/lib/files.lib.php';
|
||||||
|
|
||||||
$totalMnt = 0;
|
|
||||||
$totalnb = 0;
|
$totalnb = 0;
|
||||||
$line = 0;
|
$line = 0;
|
||||||
$cachetime = 3600;
|
$cachetime = 3600;
|
||||||
@ -173,7 +172,6 @@ class box_activity extends ModeleBoxes
|
|||||||
'td' => 'class="right"',
|
'td' => 'class="right"',
|
||||||
'text' => price($data[$j]->Mnttot,1,$langs,0,0,-1,$conf->currency),
|
'text' => price($data[$j]->Mnttot,1,$langs,0,0,-1,$conf->currency),
|
||||||
);
|
);
|
||||||
$totalMnt += $data[$j]->Mnttot;
|
|
||||||
$this->info_box_contents[$line][4] = array(
|
$this->info_box_contents[$line][4] = array(
|
||||||
'td' => 'align="right" width="18"',
|
'td' => 'align="right" width="18"',
|
||||||
'text' => $propalstatic->LibStatut($data[$j]->fk_statut,3),
|
'text' => $propalstatic->LibStatut($data[$j]->fk_statut,3),
|
||||||
@ -255,7 +253,6 @@ class box_activity extends ModeleBoxes
|
|||||||
'td' => 'class="right"',
|
'td' => 'class="right"',
|
||||||
'text' => price($data[$j]->Mnttot,1,$langs,0,0,-1,$conf->currency),
|
'text' => price($data[$j]->Mnttot,1,$langs,0,0,-1,$conf->currency),
|
||||||
);
|
);
|
||||||
$totalMnt += $data[$j]->Mnttot;
|
|
||||||
$this->info_box_contents[$line][4] = array(
|
$this->info_box_contents[$line][4] = array(
|
||||||
'td' => 'align="right" width="18"',
|
'td' => 'align="right" width="18"',
|
||||||
'text' => $commandestatic->LibStatut($data[$j]->fk_statut,0,3),
|
'text' => $commandestatic->LibStatut($data[$j]->fk_statut,0,3),
|
||||||
@ -342,10 +339,8 @@ class box_activity extends ModeleBoxes
|
|||||||
);
|
);
|
||||||
|
|
||||||
// We add only for the current year
|
// We add only for the current year
|
||||||
if ($data[$j]->annee == date("Y")) {
|
$totalnb += $data[$j]->nb;
|
||||||
$totalnb += $data[$j]->nb;
|
|
||||||
$totalMnt += $data[$j]->Mnttot;
|
|
||||||
}
|
|
||||||
$this->info_box_contents[$line][4] = array(
|
$this->info_box_contents[$line][4] = array(
|
||||||
'td' => 'align="right" width="18"',
|
'td' => 'align="right" width="18"',
|
||||||
'text' => $facturestatic->LibStatut(1,$data[$j]->fk_statut,3),
|
'text' => $facturestatic->LibStatut(1,$data[$j]->fk_statut,3),
|
||||||
@ -396,10 +391,9 @@ class box_activity extends ModeleBoxes
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (! empty($data)) {
|
if (! empty($data)) {
|
||||||
$j=0;
|
|
||||||
|
|
||||||
$alreadypaid=-1;
|
$alreadypaid=-1;
|
||||||
|
|
||||||
|
$j=0;
|
||||||
while ($j < count($data)) {
|
while ($j < count($data)) {
|
||||||
$billurl="search_status=".$data[$j]->fk_statut."&paye=0";
|
$billurl="search_status=".$data[$j]->fk_statut."&paye=0";
|
||||||
$this->info_box_contents[$line][0] = array(
|
$this->info_box_contents[$line][0] = array(
|
||||||
@ -425,7 +419,6 @@ class box_activity extends ModeleBoxes
|
|||||||
'td' => 'class="right"',
|
'td' => 'class="right"',
|
||||||
'text' => price($data[$j]->Mnttot,1,$langs,0,0,-1,$conf->currency),
|
'text' => price($data[$j]->Mnttot,1,$langs,0,0,-1,$conf->currency),
|
||||||
);
|
);
|
||||||
$totalMnt += $objp->Mnttot;
|
|
||||||
$this->info_box_contents[$line][4] = array(
|
$this->info_box_contents[$line][4] = array(
|
||||||
'td' => 'align="right" width="18"',
|
'td' => 'align="right" width="18"',
|
||||||
'text' => $facturestatic->LibStatut(0,$data[$j]->fk_statut,3, $alreadypaid),
|
'text' => $facturestatic->LibStatut(0,$data[$j]->fk_statut,3, $alreadypaid),
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user