* [bug#36205] adjust project and execution statistic data for report api.

This commit is contained in:
caoyanyi
2024-08-27 09:21:44 +08:00
committed by 王怡栋
parent a4b49ebbfc
commit dc0dbaeb7c
+6 -6
View File
@@ -162,9 +162,9 @@ class reportsEntry extends entry
$newProject->id = $project->id;
$newProject->name = $project->name;
$newProject->status = $project->status;
$newProject->progress = round($project->hours->progress, 1);
$newProject->totalConsumed = round($project->hours->totalConsumed, 1);
$newProject->totalLeft = round($project->hours->totalLeft, 1);
$newProject->progress = round($project->progress, 1);
$newProject->totalConsumed = round($project->totalConsumed, 1);
$newProject->totalLeft = round($project->totalLeft, 1);
if(isset($project->delay)) $newProject->delay = $project->delay;
$statusList['all']['total'] += 1;
@@ -206,9 +206,9 @@ class reportsEntry extends entry
$newExecution->id = $execution->id;
$newExecution->name = $execution->name;
$newExecution->status = $execution->status;
$newExecution->progress = round($execution->hours->progress, 1);
$newExecution->totalConsumed = round($execution->hours->totalConsumed, 1);
$newExecution->totalLeft = round($execution->hours->totalLeft, 1);
$newExecution->progress = round($execution->progress, 1);
$newExecution->totalConsumed = round($execution->totalConsumed, 1);
$newExecution->totalLeft = round($execution->totalLeft, 1);
if(isset($execution->delay)) $newExecution->delay = $execution->delay;
$statusList['all']['total'] += 1;