Merge branch 'fixbug_sunjun_20719' into 'master'

Fixbug sunjun 20719

See merge request easycorp/zentaopms!2726
This commit is contained in:
李玉春
2022-04-02 06:12:59 +00:00
+14
View File
@@ -2187,6 +2187,20 @@ class projectModel extends model
if($task->status != 'cancel' and $task->status != 'closed') $hour->totalLeft += $task->left;
}
$hours[$executionID] = $hour;
if($executions[$executionID]->type == 'stage' and $executions[$executionID]->grade == 2)
{
$stageParent = $executions[$executionID]->parent;
if(!isset($hours[$stageParent]))
{
$hours[$stageParent] = clone $hour;
continue;
}
$hours[$stageParent]->totalEstimate += $hour->totalEstimate;
$hours[$stageParent]->totalConsumed += $hour->totalConsumed;
$hours[$stageParent]->totalLeft += $hour->totalLeft;
}
}
/* Compute totalReal and progress. */