Skip to content

Commit

Permalink
Sum up even internal hours in main stats
Browse files Browse the repository at this point in the history
  • Loading branch information
jakubkottnauer committed Feb 5, 2024
1 parent 1f53717 commit d56a5e5
Showing 1 changed file with 1 addition and 6 deletions.
7 changes: 1 addition & 6 deletions components/entries/TaskHoursStatistic.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,7 @@ const TaskHoursStatistic = ({ entries }: { entries?: TimeEntry[] }) => {
return null;
}
const clientHours = entries
?.filter(
(e) =>
e.task.id === primaryTask?.taskId &&
// client task is not part of the default absence/0+x internal projects
!projects[e.project.id]
)
?.filter((e) => e.task.id === primaryTask?.taskId)
.reduce((acc, entry) => acc + entry.hours, 0);

return (
Expand Down

0 comments on commit d56a5e5

Please sign in to comment.