The date field is used on teacher-to-student Messages exclusively, but is nil on forum messages. Since the query was filtering by date, Laboratory's activity view showed 0 messages on every week as it never found any results.
Also, we now have soft deleted messages, and we shouldn't count those so I added that.
:dart: Goal
Properly count messages on UserStats.
:memo: Details
The
date
field is used on teacher-to-studentMessage
s exclusively, but isnil
on forum messages. Since the query was filtering bydate
, Laboratory's activity view showed0 messages
on every week as it never found any results.Also, we now have soft deleted messages, and we shouldn't count those so I added that.