|
@@ -46,10 +46,15 @@ $langs->load("projects");
|
|
|
*/
|
|
|
|
|
|
$now = dol_now();
|
|
|
+$tmp=dol_getdate($now);
|
|
|
+$day=$tmp['mday'];
|
|
|
+$month=$tmp['mon'];
|
|
|
+$year=$tmp['year'];
|
|
|
|
|
|
$projectstatic=new Project($db);
|
|
|
$taskstatic=new Task($db);
|
|
|
$projectsListId = $projectstatic->getProjectsAuthorizedForUser($user,0,1); // Return all projects I have permission on because I want my tasks and some of my task may be on a public projet that is not my project
|
|
|
+$taskstatic=new Task($db);
|
|
|
$tasktmp=new Task($db);
|
|
|
|
|
|
$title=$langs->trans("Activities");
|
|
@@ -104,7 +109,7 @@ print '<td width="50%">'.$langs->trans('ActivityOnProjectToday').'</td>';
|
|
|
print '<td width="50%" align="right">'.$langs->trans("Time").'</td>';
|
|
|
print "</tr>\n";
|
|
|
|
|
|
-$sql = "SELECT p.rowid, p.ref, p.title, SUM(tt.task_duration) as nb";
|
|
|
+$sql = "SELECT p.rowid, p.ref, p.title, p.public, SUM(tt.task_duration) as nb";
|
|
|
$sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
$sql.= ", ".MAIN_DB_PREFIX."projet_task as t";
|
|
|
$sql.= ", ".MAIN_DB_PREFIX."projet_task_time as tt";
|
|
@@ -112,9 +117,9 @@ $sql.= " WHERE t.fk_projet = p.rowid";
|
|
|
$sql.= " AND p.entity = ".$conf->entity;
|
|
|
$sql.= " AND tt.fk_task = t.rowid";
|
|
|
$sql.= " AND tt.fk_user = ".$user->id;
|
|
|
-$sql.= " AND date_format(task_date,'%y-%m-%d') = '".strftime("%y-%m-%d",$now)."'";
|
|
|
+$sql.= " AND task_date BETWEEN '".$db->idate(dol_mktime(0, 0, 0, $month, $day, $year))."' AND '".$db->idate(dol_mktime(23, 59, 59, $month, $day, $year))."'";
|
|
|
$sql.= " AND p.rowid in (".$projectsListId.")";
|
|
|
-$sql.= " GROUP BY p.rowid, p.ref, p.title";
|
|
|
+$sql.= " GROUP BY p.rowid, p.ref, p.title, p.public";
|
|
|
|
|
|
$resql = $db->query($sql);
|
|
|
if ( $resql )
|
|
@@ -130,9 +135,10 @@ if ( $resql )
|
|
|
$projectstatic->id=$row->rowid;
|
|
|
$projectstatic->ref=$row->ref;
|
|
|
$projectstatic->title=$row->title;
|
|
|
+ $projectstatic->public=$row->public;
|
|
|
print $projectstatic->getNomUrl(1, '', 1);
|
|
|
print '</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($row->nb).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($row->nb, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
$total += $row->nb;
|
|
|
}
|
|
@@ -145,80 +151,79 @@ else
|
|
|
}
|
|
|
print '<tr class="liste_total">';
|
|
|
print '<td>'.$langs->trans('Total').'</td>';
|
|
|
-print '<td align="right">'.convertSecondToTime($total).'</td>';
|
|
|
+print '<td align="right">'.convertSecondToTime($total, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
print "</table>";
|
|
|
|
|
|
-// TODO Do not use date_add function to be compatible with all database
|
|
|
-if ($db->type != 'pgsql')
|
|
|
-{
|
|
|
- /* Affichage de la liste des projets d'hier */
|
|
|
- print '<br><table class="noborder" width="100%">';
|
|
|
- print '<tr class="liste_titre">';
|
|
|
- print '<td>'.$langs->trans('ActivityOnProjectYesterday').'</td>';
|
|
|
- print '<td align="right">'.$langs->trans("Time").'</td>';
|
|
|
- print "</tr>\n";
|
|
|
|
|
|
- $sql = "SELECT p.rowid, p.ref, p.title, sum(tt.task_duration) as nb";
|
|
|
- $sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
- $sql.= ", ".MAIN_DB_PREFIX."projet_task as t";
|
|
|
- $sql.= ", ".MAIN_DB_PREFIX."projet_task_time as tt";
|
|
|
- $sql.= " WHERE t.fk_projet = p.rowid";
|
|
|
- $sql.= " AND p.entity = ".$conf->entity;
|
|
|
- $sql.= " AND tt.fk_task = t.rowid";
|
|
|
- $sql.= " AND tt.fk_user = ".$user->id;
|
|
|
- $sql.= " AND date_format(date_add(task_date, INTERVAL 1 DAY),'%y-%m-%d') = '".strftime("%y-%m-%d",$now)."'";
|
|
|
- $sql.= " AND p.rowid in (".$projectsListId.")";
|
|
|
- $sql.= " GROUP BY p.rowid, p.ref, p.title";
|
|
|
+/* Affichage de la liste des projets d'hier */
|
|
|
+print '<br><table class="noborder" width="100%">';
|
|
|
+print '<tr class="liste_titre">';
|
|
|
+print '<td>'.$langs->trans('ActivityOnProjectYesterday').'</td>';
|
|
|
+print '<td align="right">'.$langs->trans("Time").'</td>';
|
|
|
+print "</tr>\n";
|
|
|
|
|
|
- $resql = $db->query($sql);
|
|
|
- if ( $resql )
|
|
|
- {
|
|
|
- $var=true;
|
|
|
- $total=0;
|
|
|
+$sql = "SELECT p.rowid, p.ref, p.title, p.public, SUM(tt.task_duration) as nb";
|
|
|
+$sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
+$sql.= ", ".MAIN_DB_PREFIX."projet_task as t";
|
|
|
+$sql.= ", ".MAIN_DB_PREFIX."projet_task_time as tt";
|
|
|
+$sql.= " WHERE t.fk_projet = p.rowid";
|
|
|
+$sql.= " AND p.entity = ".$conf->entity;
|
|
|
+$sql.= " AND tt.fk_task = t.rowid";
|
|
|
+$sql.= " AND tt.fk_user = ".$user->id;
|
|
|
+$sql.= " AND task_date BETWEEN '".$db->idate(dol_time_plus_duree(dol_mktime(0, 0, 0, $month, $day, $year), -1, 'd'))."' AND '".$db->idate(dol_time_plus_duree(dol_mktime(23, 59, 59, $month, $day, $year), -1, 'd'))."'";
|
|
|
+$sql.= " AND p.rowid in (".$projectsListId.")";
|
|
|
+$sql.= " GROUP BY p.rowid, p.ref, p.title, p.public";
|
|
|
|
|
|
- while ($row = $db->fetch_object($resql))
|
|
|
- {
|
|
|
- $var=!$var;
|
|
|
- print "<tr ".$bc[$var].">";
|
|
|
- print '<td>';
|
|
|
- $projectstatic->id=$row->rowid;
|
|
|
- $projectstatic->ref=$row->ref;
|
|
|
- $projectstatic->title=$row->title;
|
|
|
- print $projectstatic->getNomUrl(1, '', 1);
|
|
|
- print '</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($row->nb).'</td>';
|
|
|
- print "</tr>\n";
|
|
|
- $total += $row->nb;
|
|
|
- }
|
|
|
+$resql = $db->query($sql);
|
|
|
+if ( $resql )
|
|
|
+{
|
|
|
+ $var=true;
|
|
|
+ $total=0;
|
|
|
|
|
|
- $db->free($resql);
|
|
|
- }
|
|
|
- else
|
|
|
+ while ($row = $db->fetch_object($resql))
|
|
|
{
|
|
|
- dol_print_error($db);
|
|
|
+ $var=!$var;
|
|
|
+ print "<tr ".$bc[$var].">";
|
|
|
+ print '<td>';
|
|
|
+ $projectstatic->id=$row->rowid;
|
|
|
+ $projectstatic->ref=$row->ref;
|
|
|
+ $projectstatic->title=$row->title;
|
|
|
+ $projectstatic->public=$row->public;
|
|
|
+ print $projectstatic->getNomUrl(1, '', 1);
|
|
|
+ print '</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($row->nb, 'allhourmin').'</td>';
|
|
|
+ print "</tr>\n";
|
|
|
+ $total += $row->nb;
|
|
|
}
|
|
|
- print '<tr class="liste_total">';
|
|
|
- print '<td>'.$langs->trans('Total').'</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($total).'</td>';
|
|
|
- print "</tr>\n";
|
|
|
- print "</table>";
|
|
|
+
|
|
|
+ $db->free($resql);
|
|
|
}
|
|
|
+else
|
|
|
+{
|
|
|
+ dol_print_error($db);
|
|
|
+}
|
|
|
+print '<tr class="liste_total">';
|
|
|
+print '<td>'.$langs->trans('Total').'</td>';
|
|
|
+print '<td align="right">'.convertSecondToTime($total, 'allhourmin').'</td>';
|
|
|
+print "</tr>\n";
|
|
|
+print "</table>";
|
|
|
|
|
|
|
|
|
-// TODO Do not use week function to be compatible with all database
|
|
|
+
|
|
|
+/*
|
|
|
if ($db->type != 'pgsql')
|
|
|
{
|
|
|
print '<br>';
|
|
|
|
|
|
- /* Affichage de la liste des projets de la semaine */
|
|
|
+ // Affichage de la liste des projets de la semaine
|
|
|
print '<table class="noborder" width="100%">';
|
|
|
print '<tr class="liste_titre">';
|
|
|
print '<td>'.$langs->trans("ActivityOnProjectThisWeek").'</td>';
|
|
|
print '<td align="right">'.$langs->trans("Time").'</td>';
|
|
|
print "</tr>\n";
|
|
|
|
|
|
- $sql = "SELECT p.rowid, p.ref, p.title, SUM(tt.task_duration) as nb";
|
|
|
+ $sql = "SELECT p.rowid, p.ref, p.title, p.public, SUM(tt.task_duration) as nb";
|
|
|
$sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
$sql.= " , ".MAIN_DB_PREFIX."projet_task as t";
|
|
|
$sql.= " , ".MAIN_DB_PREFIX."projet_task_time as tt";
|
|
@@ -226,7 +231,7 @@ if ($db->type != 'pgsql')
|
|
|
$sql.= " AND p.entity = ".$conf->entity;
|
|
|
$sql.= " AND tt.fk_task = t.rowid";
|
|
|
$sql.= " AND tt.fk_user = ".$user->id;
|
|
|
- $sql.= " AND week(task_date) = '".strftime("%W",time())."'";
|
|
|
+ $sql.= " AND task_date >= '".$db->idate(dol_get_first_day($year, $month)).'" AND ...";
|
|
|
$sql.= " AND p.rowid in (".$projectsListId.")";
|
|
|
$sql.= " GROUP BY p.rowid, p.ref, p.title";
|
|
|
|
|
@@ -244,9 +249,10 @@ if ($db->type != 'pgsql')
|
|
|
$projectstatic->id=$row->rowid;
|
|
|
$projectstatic->ref=$row->ref;
|
|
|
$projectstatic->title=$row->title;
|
|
|
+ $projectstatic->public=$row->public;
|
|
|
print $projectstatic->getNomUrl(1, '', 1);
|
|
|
print '</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($row->nb).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($row->nb, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
$total += $row->nb;
|
|
|
}
|
|
@@ -259,10 +265,12 @@ if ($db->type != 'pgsql')
|
|
|
}
|
|
|
print '<tr class="liste_total">';
|
|
|
print '<td>'.$langs->trans('Total').'</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($total).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($total, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
print "</table><br>";
|
|
|
+
|
|
|
}
|
|
|
+*/
|
|
|
|
|
|
/* Affichage de la liste des projets du mois */
|
|
|
if (! empty($conf->global->PROJECT_TASK_TIME_MONTH))
|
|
@@ -273,7 +281,7 @@ if (! empty($conf->global->PROJECT_TASK_TIME_MONTH))
|
|
|
print '<td align="right">'.$langs->trans("Time").'</td>';
|
|
|
print "</tr>\n";
|
|
|
|
|
|
- $sql = "SELECT p.rowid, p.ref, p.title, SUM(tt.task_duration) as nb";
|
|
|
+ $sql = "SELECT p.rowid, p.ref, p.title, p.public, SUM(tt.task_duration) as nb";
|
|
|
$sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
$sql.= ", ".MAIN_DB_PREFIX."projet_task as t";
|
|
|
$sql.= ", ".MAIN_DB_PREFIX."projet_task_time as tt";
|
|
@@ -281,9 +289,9 @@ if (! empty($conf->global->PROJECT_TASK_TIME_MONTH))
|
|
|
$sql.= " AND p.entity = ".$conf->entity;
|
|
|
$sql.= " AND tt.fk_task = t.rowid";
|
|
|
$sql.= " AND tt.fk_user = ".$user->id;
|
|
|
- $sql.= " AND date_format(task_date,'%y-%m') = '".strftime("%y-%m",$now)."'";
|
|
|
+ $sql.= " AND task_date BETWEEN '".$db->idate(dol_get_first_day($year, $month))."' AND '".$db->idate(dol_get_last_day($year, $month))."'";
|
|
|
$sql.= " AND p.rowid in (".$projectsListId.")";
|
|
|
- $sql.= " GROUP BY p.rowid, p.ref, p.title";
|
|
|
+ $sql.= " GROUP BY p.rowid, p.ref, p.title, p.public";
|
|
|
|
|
|
$resql = $db->query($sql);
|
|
|
if ( $resql )
|
|
@@ -299,7 +307,7 @@ if (! empty($conf->global->PROJECT_TASK_TIME_MONTH))
|
|
|
$projectstatic->title=$row->title;
|
|
|
print $projectstatic->getNomUrl(1, '', 1);
|
|
|
print '</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($row->nb).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($row->nb, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
$var=!$var;
|
|
|
}
|
|
@@ -311,7 +319,7 @@ if (! empty($conf->global->PROJECT_TASK_TIME_MONTH))
|
|
|
}
|
|
|
print '<tr class="liste_total">';
|
|
|
print '<td>'.$langs->trans('Total').'</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($total).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($total, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
print "</table>";
|
|
|
}
|
|
@@ -325,7 +333,7 @@ if (! empty($conf->global->PROJECT_TASK_TIME_YEAR))
|
|
|
print '<td align="right">'.$langs->trans("Time").'</td>';
|
|
|
print "</tr>\n";
|
|
|
|
|
|
- $sql = "SELECT p.rowid, p.ref, p.title, SUM(tt.task_duration) as nb";
|
|
|
+ $sql = "SELECT p.rowid, p.ref, p.title, p.public, SUM(tt.task_duration) as nb";
|
|
|
$sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
$sql.= ", ".MAIN_DB_PREFIX."projet_task as t";
|
|
|
$sql.= ", ".MAIN_DB_PREFIX."projet_task_time as tt";
|
|
@@ -335,7 +343,7 @@ if (! empty($conf->global->PROJECT_TASK_TIME_YEAR))
|
|
|
$sql.= " AND tt.fk_user = ".$user->id;
|
|
|
$sql.= " AND YEAR(task_date) = '".strftime("%Y",$now)."'";
|
|
|
$sql.= " AND p.rowid in (".$projectsListId.")";
|
|
|
- $sql.= " GROUP BY p.rowid, p.ref, p.title";
|
|
|
+ $sql.= " GROUP BY p.rowid, p.ref, p.title, p.public";
|
|
|
|
|
|
$var=false;
|
|
|
$resql = $db->query($sql);
|
|
@@ -348,9 +356,10 @@ if (! empty($conf->global->PROJECT_TASK_TIME_YEAR))
|
|
|
$projectstatic->id=$row->rowid;
|
|
|
$projectstatic->ref=$row->ref;
|
|
|
$projectstatic->title=$row->title;
|
|
|
+ $projectstatic->public=$row->public;
|
|
|
print $projectstatic->getNomUrl(1, '', 1);
|
|
|
print '</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($row->nb).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($row->nb, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
$var=!$var;
|
|
|
}
|
|
@@ -362,31 +371,71 @@ if (! empty($conf->global->PROJECT_TASK_TIME_YEAR))
|
|
|
}
|
|
|
print '<tr class="liste_total">';
|
|
|
print '<td>'.$langs->trans('Total').'</td>';
|
|
|
- print '<td align="right">'.convertSecondToTime($total).'</td>';
|
|
|
+ print '<td align="right">'.convertSecondToTime($total, 'allhourmin').'</td>';
|
|
|
print "</tr>\n";
|
|
|
print "</table>";
|
|
|
}
|
|
|
|
|
|
if (empty($conf->global->PROJECT_HIDE_TASKS) && ! empty($conf->global->PROJECT_SHOW_TASK_LIST_ON_PROJECT_AREA))
|
|
|
{
|
|
|
+ // Get id of types of contacts for projects (This list never contains a lot of elements)
|
|
|
+ $listofprojectcontacttype=array();
|
|
|
+ $sql = "SELECT ctc.rowid, ctc.code FROM ".MAIN_DB_PREFIX."c_type_contact as ctc";
|
|
|
+ $sql.= " WHERE ctc.element = '" . $projectstatic->element . "'";
|
|
|
+ $sql.= " AND ctc.source = 'internal'";
|
|
|
+ $resql = $db->query($sql);
|
|
|
+ if ($resql)
|
|
|
+ {
|
|
|
+ while($obj = $db->fetch_object($resql))
|
|
|
+ {
|
|
|
+ $listofprojectcontacttype[$obj->rowid]=$obj->code;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else dol_print_error($db);
|
|
|
+ if (count($listofprojectcontacttype) == 0) $listofprojectcontacttype[0]='0'; // To avoid sql syntax error if not found
|
|
|
+ // Get id of types of contacts for tasks (This list never contains a lot of elements)
|
|
|
+ $listoftaskcontacttype=array();
|
|
|
+ $sql = "SELECT ctc.rowid, ctc.code FROM ".MAIN_DB_PREFIX."c_type_contact as ctc";
|
|
|
+ $sql.= " WHERE ctc.element = '" . $taskstatic->element . "'";
|
|
|
+ $sql.= " AND ctc.source = 'internal'";
|
|
|
+ $resql = $db->query($sql);
|
|
|
+ if ($resql)
|
|
|
+ {
|
|
|
+ while($obj = $db->fetch_object($resql))
|
|
|
+ {
|
|
|
+ $listoftaskcontacttype[$obj->rowid]=$obj->code;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ else dol_print_error($db);
|
|
|
+ if (count($listoftaskcontacttype) == 0) $listoftaskcontacttype[0]='0'; // To avoid sql syntax error if not found
|
|
|
+
|
|
|
+
|
|
|
// Tasks for all resources of all opened projects and time spent for each task/resource
|
|
|
// This list can be very long, so we don't show it by default on task area. We prefer to use the list page.
|
|
|
// Add constant PROJECT_SHOW_TASK_LIST_ON_PROJECT_AREA to show this list
|
|
|
|
|
|
$max = (empty($conf->global->PROJECT_LIMIT_TASK_PROJECT_AREA)?1000:$conf->global->PROJECT_LIMIT_TASK_PROJECT_AREA);
|
|
|
|
|
|
- $sql = "SELECT p.ref, p.title, p.rowid as projectid, p.fk_statut as status, p.fk_opp_status as opp_status, p.dateo as projdateo, p.datee as projdatee,";
|
|
|
+ $sql = "SELECT p.ref, p.title, p.rowid as projectid, p.fk_statut as status, p.fk_opp_status as opp_status, p.public, p.dateo as projdateo, p.datee as projdatee,";
|
|
|
$sql.= " t.label, t.rowid as taskid, t.planned_workload, t.duration_effective, t.progress, t.dateo, t.datee, SUM(tasktime.task_duration) as timespent";
|
|
|
$sql.= " FROM ".MAIN_DB_PREFIX."projet as p";
|
|
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."societe as s on p.fk_soc = s.rowid";
|
|
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."projet_task as t on t.fk_projet = p.rowid";
|
|
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."projet_task_time as tasktime on tasktime.fk_task = t.rowid";
|
|
|
$sql.= " LEFT JOIN ".MAIN_DB_PREFIX."user as u on tasktime.fk_user = u.rowid";
|
|
|
+ if ($mine)
|
|
|
+ {
|
|
|
+ $sql.= ", " . MAIN_DB_PREFIX . "element_contact as ect";
|
|
|
+ }
|
|
|
$sql.= " WHERE p.entity = ".$conf->entity;
|
|
|
- if ($mine || empty($user->rights->projet->all->lire)) $sql.= " AND p.rowid IN (".$projectsListId.")";
|
|
|
- if ($socid) $sql.= " AND (p.fk_soc IS NULL OR p.fk_soc = 0 OR p.fk_soc = ".$socid.")";
|
|
|
+ if ($mine || empty($user->rights->projet->all->lire)) $sql.= " AND p.rowid IN (".$projectsListId.")"; // project i have permission on
|
|
|
+ if ($mine) // this may duplicate record if we are contact twice
|
|
|
+ {
|
|
|
+ $sql.= " AND ect.fk_c_type_contact IN (".join(',',array_keys($listoftaskcontacttype)).") AND ect.element_id = t.rowid AND ect.fk_socpeople = ".$user->id;
|
|
|
+ }
|
|
|
+ if ($socid) $sql.= " AND (p.fk_soc IS NULL OR p.fk_soc = 0 OR p.fk_soc = ".$socid.")";
|
|
|
$sql.= " AND p.fk_statut=1";
|
|
|
- $sql.= " GROUP BY p.ref, p.title, p.rowid, t.label, t.rowid, t.planned_workload, t.duration_effective, t.progress, t.dateo, t.datee";
|
|
|
+ $sql.= " GROUP BY p.ref, p.title, p.rowid, p.fk_statut, p.fk_opp_status, p.public, t.label, t.rowid, t.planned_workload, t.duration_effective, t.progress, t.dateo, t.datee";
|
|
|
$sql.= " ORDER BY t.dateo desc, t.rowid desc, t.datee";
|
|
|
$sql.= $db->plimit($max+1); // We want more to know if we have more than limit
|
|
|
|
|
@@ -435,6 +484,7 @@ if (empty($conf->global->PROJECT_HIDE_TASKS) && ! empty($conf->global->PROJECT_S
|
|
|
$projectstatic->ref=$obj->ref;
|
|
|
$projectstatic->title=$obj->title;
|
|
|
$projectstatic->statut = $obj->status;
|
|
|
+ $projectstatic->public = $obj->public;
|
|
|
$projectstatic->dateo = $db->jdate($obj->projdateo);
|
|
|
$projectstatic->datee = $db->jdate($obj->projdatee);
|
|
|
|
|
@@ -468,10 +518,10 @@ if (empty($conf->global->PROJECT_HIDE_TASKS) && ! empty($conf->global->PROJECT_S
|
|
|
if ($taskstatic->hasDelay()) print img_warning($langs->trans("Late"));
|
|
|
print '</td>';
|
|
|
print '<td align="right"><a href="'.DOL_URL_ROOT.'/projet/tasks/time.php?id='.$obj->taskid.'&withproject=1">';
|
|
|
- print convertSecondToTime($obj->planned_workload, 'all');
|
|
|
+ print convertSecondToTime($obj->planned_workload, 'allhourmin');
|
|
|
print '</a></td>';
|
|
|
print '<td align="right"><a href="'.DOL_URL_ROOT.'/projet/tasks/time.php?id='.$obj->taskid.'&withproject=1">';
|
|
|
- print convertSecondToTime($obj->timespent, 'all');
|
|
|
+ print convertSecondToTime($obj->timespent, 'allhourmin');
|
|
|
print '</a></td>';
|
|
|
print '<td align="right">';
|
|
|
if (! empty($obj->taskid))
|