Skip to content
Snippets Groups Projects
Commit 66e0c128 authored by Laurent Destailleur's avatar Laurent Destailleur
Browse files

Disable a bugged box

parent 74e8738c
No related branches found
No related tags found
No related merge requests found
......@@ -25,6 +25,7 @@
include_once(DOL_DOCUMENT_ROOT."/core/boxes/modules_boxes.php");
require_once(DOL_DOCUMENT_ROOT."/core/lib/date.lib.php");
/**
* Class to manage the box to show last task
*/
......@@ -36,6 +37,7 @@ class box_task extends ModeleBoxes
//var $depends = array("projet");
var $db;
var $param;
var $enabled = 0; // Disabled because bugged.
var $info_box_head = array();
var $info_box_contents = array();
......@@ -79,8 +81,8 @@ class box_task extends ModeleBoxes
// list the summary of the orders
if ($user->rights->projet->lire) {
$sql = "SELECT pt.fk_statut, count(pt.rowid) as nb, sum(ptt.task_duration) as durationtot, sum(pt.planned_workload) as plannedtot";
// FIXME fk_statut on a task is not be used. We use the percent. This means this box is useless.
$sql = "SELECT pt.fk_statut, count(DISTINCT pt.rowid) as nb, sum(ptt.task_duration) as durationtot, sum(pt.planned_workload) as plannedtot";
$sql.= " FROM ".MAIN_DB_PREFIX."projet_task as pt, ".MAIN_DB_PREFIX."projet_task_time as ptt";
$sql.= " WHERE pt.datec BETWEEN '".$this->db->idate(dol_get_first_day(date("Y"), 1))."' AND '".$this->db->idate(dol_get_last_day(date("Y"), 12))."'";
$sql.= " AND pt.rowid = ptt.fk_task";
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment