Display unfinished subtasks in the calendar

This commit is contained in:
Frederic Guillot
2015-02-15 21:00:04 -05:00
parent 321b1914ef
commit 353117f44e
2 changed files with 22 additions and 4 deletions

View File

@@ -169,7 +169,13 @@ class SubtaskTimeTracking extends Base
$start_column = $this->db->escapeIdentifier('start');
$end_column = $this->db->escapeIdentifier('end');
return "(($start_column >= '$start_time' AND $start_column <= '$end_time') OR ($start_column <= '$start_time' AND $end_column >= '$start_time'))";
$conditions = array(
"($start_column >= '$start_time' AND $start_column <= '$end_time')",
"($start_column <= '$start_time' AND $end_column >= '$start_time')",
"($start_column <= '$start_time' AND $end_column = '0')",
);
return '('.implode(' OR ', $conditions).')';
}
/**