From b77d2f2ff2d71ac8c1948ee25db8e2b63804f78f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Fr=C3=A9d=C3=A9ric=20FRANCE?= Date: Mon, 14 Oct 2019 23:27:37 +0200 Subject: [PATCH] Update box_task.php --- htdocs/core/boxes/box_task.php | 25 +++++++++++++------------ 1 file changed, 13 insertions(+), 12 deletions(-) diff --git a/htdocs/core/boxes/box_task.php b/htdocs/core/boxes/box_task.php index 59b31086db5..dbe1757d55d 100644 --- a/htdocs/core/boxes/box_task.php +++ b/htdocs/core/boxes/box_task.php @@ -134,7 +134,13 @@ class box_task extends ModeleBoxes }); }); '; - + // set cookie by js + $boxcontent.=''; + $this->info_box_contents[0][] = array( + 'tr'=>'class="nohover"', + 'td' => 'class="nohover"', + 'textnoformat' => $boxcontent, + ); $sql = "SELECT pt.rowid, pt.ref, pt.fk_projet, pt.fk_task_parent, pt.datec, pt.dateo, pt.datee, pt.datev, pt.label, pt.description, pt.duration_effective, pt.planned_workload, pt.progress"; @@ -163,7 +169,7 @@ class box_task extends ModeleBoxes $sql.= $this->db->plimit($max, 0); $result = $this->db->query($sql); - $i = 0; + $i = 1; if ($result) { $num = $this->db->num_rows($result); while ($objp = $this->db->fetch_object($result)) { @@ -183,8 +189,12 @@ class box_task extends ModeleBoxes $label = $projectstatic->getNomUrl(1).' '.$taskstatic->getNomUrl(1).' '.dol_htmlentities($taskstatic->label); - $boxcontent.= getTaskProgressView($taskstatic, $label, true, false, true); + $boxcontent = getTaskProgressView($taskstatic, $label, true, false, true); + $this->info_box_contents[$i][] = array( + 'td' => '', + 'text' => $boxcontent, + ); $i++; } } else { @@ -192,15 +202,6 @@ class box_task extends ModeleBoxes } } - // set cookie by js - if(empty($i)){ - $boxcontent.=''; - } - - $this->info_box_contents[0][] = array( - 'td' => '', - 'text' => $boxcontent, - ); } /**