If looking at totals roll up should be totals, if percentage then percentages should show
This commit is contained in:
Trey t
2022-02-10 16:15:06 -06:00
parent f66caf93dd
commit 97e6e52c8c
4 changed files with 114 additions and 59 deletions

View File

@@ -40,12 +40,8 @@ struct HeaderPercView: View {
let moodEntries = moodEntries.filter({
Int($0.moodValue) == mood.rawValue
})
let total = moodEntries.count
let perc = (Float(total) / Float(totalEntryCount)) * 100
entries.append((mood, total, perc))
}
}