diff --git a/htdocs/core/lib/project.lib.php b/htdocs/core/lib/project.lib.php index b7c2279188d..bbc6da6a7e4 100644 --- a/htdocs/core/lib/project.lib.php +++ b/htdocs/core/lib/project.lib.php @@ -929,7 +929,7 @@ function projectLinesa(&$inc, $parent, &$lines, &$level, $var, $showproject, &$t } } - if (($total_projectlinesa_planned > 0 || $total_projectlinesa_spent > 0 || $total_projectlinesa_tobill > 0 || $total_projectlinesa_billed > 0) + if (($total_projectlinesa_planned > 0 || $total_projectlinesa_spent > 0 || $total_projectlinesa_tobill > 0 || $total_projectlinesa_billed > 0 || $total_budget_amount > 0) && $level <= 0) { print ''; print ''.$langs->trans("Total").''; @@ -1031,8 +1031,8 @@ function projectLinesa(&$inc, $parent, &$lines, &$level, $var, $showproject, &$t } if (count($arrayfields) > 0 && !empty($arrayfields['t.budget_amount']['checked'])) { - print ''; - price($total_budget_amount, 0, $langs, 1, 0, 0, $conf->currency); + print ''; + print price($total_budget_amount, 0, $langs, 1, 0, 0, $conf->currency); print ''; } diff --git a/htdocs/projet/tasks/list.php b/htdocs/projet/tasks/list.php index fc316fb2705..e1ed162f9c2 100644 --- a/htdocs/projet/tasks/list.php +++ b/htdocs/projet/tasks/list.php @@ -766,15 +766,17 @@ if (!empty($arrayfields['t.progress']['checked'])) { print ''; print ''; } + +if (!empty($arrayfields['t.progress_summary']['checked'])) { + print ''; +} + if (!empty($arrayfields['t.budget_amount']['checked'])) { print ''; print ''; print ''; } -if (!empty($arrayfields['t.progress_summary']['checked'])) { - print ''; -} if (!empty($arrayfields['t.tobill']['checked'])) { print ''; } @@ -1146,7 +1148,7 @@ while ($i < min($num, $limit)) { } $totalarray['val']['t.budget_amount'] += $obj->budget_amount; if (!$i) { - $totalarray['totalbudgetamount'] = $totalarray['nbfield']; + $totalarray['totalbudget_amount'] = $totalarray['nbfield']; } $totalarray['totalbudgetamount'] += $obj->budget_amount; print ''; @@ -1267,7 +1269,7 @@ if (isset($totalarray['totaldurationeffectivefield']) || isset($totalarray['tota print ''.convertSecondToTime($totalarray['totaltobill'], $plannedworkloadoutputformat).''; } elseif ($totalarray['totalbilledfield'] == $i) { print ''.convertSecondToTime($totalarray['totalbilled'], $plannedworkloadoutputformat).''; - } elseif ($totalarray['totalbudgetamount'] == $i) { + } elseif ($totalarray['totalbudget_amount'] == $i) { print ''.price($totalarray['totalbudgetamount'], 0, $langs, 1, 0, 0, $conf->currency).''; } else { print '';