* Code for task effort.

This commit is contained in:
sunguangming
2022-09-02 14:17:39 +08:00
parent dbcc64cc4c
commit 54c54108e6
+1 -2
View File
@@ -505,9 +505,8 @@ class projectModel extends model
$projects = array();
$totalConsumeds = $this->dao->select('t2.project,ROUND(SUM(t1.consumed), 1) AS totalConsumed')->from(TABLE_EFFORT)->alias('t1')
->leftJoin(TABLE_TASK)->alias('t2')->on('t1.objectID=t2.id')
->leftJoin(TABLE_TASK)->alias('t2')->on("t1.objectID=t2.id and t1.objectType = 'task'")
->where('t2.project')->in($projectIdList)
->andWhere('t1.objectType')->eq('task')
->beginIF($time == 'THIS_YEAR')->andWhere('LEFT(t1.`date`, 4)')->eq(date('Y'))->fi()
->andWhere('t2.deleted')->eq(0)
->andWhere('t2.parent')->lt(1)