I am developing a platform to process incidents in my school. For each student record, I have 15 columns containing the email address of their teachers.
First Name | Last Name | Teacher Email 1 | Teacher Email 2 etc…
When an incident occurs, and only one student is involved, the incident record will look like this:
Incident # | Student Name | Here are many other fields related to the incident | teacherxx@email.com | teacheryy@email.com, etc…
When an incident occurs, and more than one student is involved, the incident record will look like this (in the example below two students are involved):
Incident # | Student Name 1 Student name 2 | Here are many other fields related to the incident | teacherxx1@email.com,teacherww2@email.com | teacheryy1@email.com,teacherzz2@email.com, etc…
The scenario I am developing is looking at ALL the incidents created the last 24 hours, and I want to send an email to each teachers with a digest in come ways of all incident
So a teacher will receive one email with X incidents reported the last 24 hours, then a second teachers will receive a report with Y incidents reported the last 24 hours.
I would need some help to go in the right direction, I am not sure how to design this one.