* if status of task is wait, recording estimate will change status.

This commit is contained in:
zhujinyong
2013-03-03 01:03:54 +00:00
parent 67b4e1d74f
commit c7ead516a6
+2
View File
@@ -447,9 +447,11 @@ class taskModel extends model
$this->loadModel('action')->create('task', $taskID, 'RecordEstimate', '', $estimate->consumed);
}
$status = $task->status == 'wait' ? 'doing' : $task->status;
$this->dao->update(TABLE_TASK)
->set('consumed')->eq($task->consumed + $consumed)
->set('`left`')->eq($left)
->set('status')->eq($status)
->where('id')->eq($taskID)
->exec();
}