mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-24 01:11:38 -05:00
Use iso8601 to validate scheduled_for datetime.
Added a validation method that always fails for scheduled notifications. Comment out config for scheduled task. The schedule notifications will be turned on once we can invite services to use it. Waiting for the service permission story, must commit this in order to keep things from going stale.
This commit is contained in:
@@ -891,8 +891,7 @@ class Notification(db.Model):
|
||||
"sent_at": self.sent_at.strftime(DATETIME_FORMAT) if self.sent_at else None,
|
||||
"completed_at": self.completed_at(),
|
||||
"scheduled_for": convert_bst_to_utc(self.scheduled_notification.scheduled_for
|
||||
).strftime(
|
||||
"%Y-%m-%d %H:%M") if self.scheduled_notification else None
|
||||
).strftime(DATETIME_FORMAT) if self.scheduled_notification else None
|
||||
}
|
||||
|
||||
return serialized
|
||||
|
||||
Reference in New Issue
Block a user