Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Summary
This pull request fixes the bug that the "no check-in" filter was showing classes in which all groups were already sent a check-in email.
This bug stemmed from the fact that in order to display the order of email templates accurately in the send email modal, the backend fields were updated with numbers to reflect that order of email templates alphanumerically, rather than fixing the order on the frontend. Although this field name was changed in the database, it was not reflected in the filter logic. In this PR, filter logic was then updated to reflect the updated field.
Test Plan
In this example, ECON 1110 and PHYS 2213 students were matched, and updated the
templateTimestamps
field in the emulator database through the backend for ECON 1100. This was done through calling theupdateGroupTimestamp
inbackend/functions/src/emailing/functions.ts
.Since the Microsoft Graph PR (#165) was not merged, I was not able to use the emailing feature via the frontend, which is why I called the backend function instead so that the database can update appropriately.
After applying the filter, ECON 1100 no longer shows up when applying the "no checkin email" filter, as expected.
Notes
This change has no affect on the ability of the system to get email templates. Although the id for the check-in email is
check-in
, it is still able to retrieve the correct email template since the filter does not communicate with the email templates.Breaking Changes