You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Create NotificationType Model
- Create Notifications module and NotificationType model
- Start migration for adding notifications
- No functionalities added yet only template code
* Configure Oban and Bamboo for notifications system
* Create NotificationConfig Model
* Create TimeOption Model
* Create NotificationPreference Model
* Create SentNotification Model
* Add Email Field to User Model
* fix: Fix Oban configuration
* chore: Add dependency on bamboo_phoenix for email template rendering
* feat: Implement Oban job for avenger backlog emails
* chore: Prevent browser from opening automatically when a local email is sent
* Add migrations for notification triggers and avenger backlog
notification entry
* Implement notification configuration checks
* Fix formatting errors
* fix: Fix notifications schema typos
Changes:
* Replaced is_enable to is_enabled for Notification Preferences
* Update default is_enabled to true for Notifcation Types
* fix: Fix test configurations not being applied
`import_config` must always appear at the bottom for environment
specific configurations to be applied correctly. All configurations
after this line will overwrite configurations that exists in the
environment specific ones.
* chore: remove unused controllers and views
- remove auto-generated controllers and views that are not used
* chore: Add tests for notifications
* chore: Add test for avenger backlog email
* chore: Resolve style violations
* chore: Resolve style violations
* chore: Resolve style violations
* style: fix formatting
* fix: Fix bad refactoring
* fix: Fix testing environment with Oban and Bamboo
* test: add tests for notification types
* test: add tests for time options
* chore: Update constraints and changesets for notification models
* chore: Update default behaviour for no time_option in user preference
If user preference has no time option, use the time_option from
notification_config instead. This is so that the behaviour of these
users with no preferences would always follow the default chosen by the
course admin
* style: fix formatting
* test: add tests for sent notifications
* Add tests for notifications module
* fix: Fix testing with Oban
Oban introduced changes to testing in v2.12, this commit changes the old
test configurations to the new one recommended by official docs.
* Add more tests for notifications module
* test: add tests for NotificationWorker
* style: fix formatting
* style: fix formatting
* style: fix formatting
* fix: Fix tests under notification types name constraints
* feat: Implement job for assessment submission mail
* fix: Fix assessment submission worker
* chore: Add test for assessment submission
* chore: Add migration to populate existing nus users' emails
Current nus users will have their email attribute populated based on
their username. nus users are identified from the provider attribute.
Future nus users will have their email attribute populated on creation
ideally.
* feat: implement sent_notifications
- move mailing logic to notification worker
- insert into sent_notifications when email is sent out successfully
* fix: fix tests
* style: fix formatting
* fix: fix guard clauses
- move guard clauses to prevent unnecessary querying
* fix: Fix db triggers not running for assessment submission notifications
---------
Co-authored-by: Goh Jun Yi <[email protected]>
Co-authored-by: Martin Henz <[email protected]>
@@ -1151,7 +1164,8 @@ defmodule Cadet.Assessments do
1151
1164
{:ok,String.t()}
1152
1165
defall_submissions_by_grader_for_index(
1153
1166
grader=%CourseRegistration{course_id: course_id},
1154
-
group_only\\false
1167
+
group_only\\false,
1168
+
ungraded_only\\false
1155
1169
)do
1156
1170
show_all=notgroup_only
1157
1171
@@ -1161,6 +1175,11 @@ defmodule Cadet.Assessments do
1161
1175
else:
1162
1176
"where s.student_id in (select cr.id from course_registrations cr inner join groups g on cr.group_id = g.id where g.leader_id = $2) or s.student_id = $2"
0 commit comments