Skip to content

Commit

Permalink
Calculate kiky hours from the current year only.
Browse files Browse the repository at this point in the history
  • Loading branch information
joaalto committed Jan 20, 2018
1 parent 60f5dfa commit 9af4368
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/DateUtils.elm
Expand Up @@ -91,7 +91,10 @@ calculateDailyHours dateEntries model =
List.sum
(List.map
(\entry ->
if List.any (\t -> t.id == entry.taskId) model.specialTasks.kiky then
if
(year (dateEntries.date) == year (model.currentDate))
&& List.any (\t -> t.id == entry.taskId) model.specialTasks.kiky
then
entry.hours
else
0
Expand Down

0 comments on commit 9af4368

Please sign in to comment.