From d409a534d749bb733e38c80330c852a281b80102 Mon Sep 17 00:00:00 2001 From: Florian HENRY Date: Thu, 23 Jun 2022 10:20:26 +0200 Subject: [PATCH] Ok better --- htdocs/fichinter/index.php | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/htdocs/fichinter/index.php b/htdocs/fichinter/index.php index d4940ccb806..f40932c7faf 100644 --- a/htdocs/fichinter/index.php +++ b/htdocs/fichinter/index.php @@ -114,7 +114,8 @@ if ($resql) { print '
'; print ''; print ''."\n"; - $listofstatus = array(Fichinter::STATUS_DRAFT, Fichinter::STATUS_VALIDATED, Fichinter::STATUS_BILLED, Fichinter::STATUS_CLOSED); + $listofstatus = array(Fichinter::STATUS_DRAFT, Fichinter::STATUS_VALIDATED); + if (!empty($conf->global->FICHINTER_CLASSIFY_BILLED)) $listofstatus[] = Fichinter::STATUS_BILLED; foreach ($listofstatus as $status) { $dataseries[] = array($fichinterstatic->LibStatut($status, 1), (isset($vals[$status]) ? (int) $vals[$status] : 0)); @@ -128,9 +129,6 @@ if ($resql) { if ($status == Fichinter::STATUS_BILLED) { $colorseries[$status] = $badgeStatus4; } - if ($status == Fichinter::STATUS_CLOSED) { - $colorseries[$status] = $badgeStatus6; - } } if ($conf->use_javascript_ajax) { @@ -149,21 +147,15 @@ if ($resql) { print ''; } - $bool = false; foreach ($listofstatus as $status) { if (!$conf->use_javascript_ajax) { print ''; print ''; - print ''; print "\n"; - if ($status == 3 && !$bool) { - $bool = true; - } else { - $bool = false; - } } } //if ($totalinprocess != $total)
'.$langs->trans("Statistics").' - '.$langs->trans("Interventions").'
'.$fichinterstatic->LibStatut($status, $bool, 0).''.(isset($vals[$status.$bool]) ? $vals[$status.$bool] : 0).' '; - print $fichinterstatic->LibStatut($status, $bool, 3); + print ''.(isset($vals[$status]) ? $vals[$status] : 0).' '; + print $fichinterstatic->LibStatut($status, 3); print ''; print '