diff options
author | Özgür Kesim <oec@kesim.org> | 2024-11-28 18:50:56 +0100 |
---|---|---|
committer | Özgür Kesim <oec@kesim.org> | 2024-11-28 18:50:56 +0100 |
commit | 888ebed344d3c2fdb8140a3eeaf20f5139375932 (patch) | |
tree | b50b853158c2c469c7f80b8fd3809de45a1e562e /zeitgeist.go | |
parent | 255c624b733e44e39392dd565da55d6f2350076f (diff) |
added global totals
Diffstat (limited to 'zeitgeist.go')
-rw-r--r-- | zeitgeist.go | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/zeitgeist.go b/zeitgeist.go index 9dc6e67..a4c05c4 100644 --- a/zeitgeist.go +++ b/zeitgeist.go @@ -888,11 +888,14 @@ type AllTotals struct { func (p *Project) Totals() (at *AllTotals) { at = &AllTotals{ - // TODO: fill in totals here, too WP: make(map[string]*WPTotals), } for n := range p.Workpackages { - at.WP[n], _ = p.TotalWP(n) + t, _ := p.TotalWP(n) + at.WP[n] = t + at.Totals.Budgeted += t.Budgeted + at.Totals.Planned += t.Planned + at.Totals.Done += t.Done } return at } |