mirror of
https://github.com/GSA/notifications-api.git
synced 2025-12-24 01:11:38 -05:00
Change notification status of failed letters
- Changed the notification status of letters for letters that DVLA marks as 'failed' from NOTIFICATION_TECHNICAL_FAILURE to NOTIFICATION_TEMPORARY_FAILURE.
This commit is contained in:
@@ -63,6 +63,7 @@ from app.models import (
|
||||
LETTER_TYPE,
|
||||
NOTIFICATION_DELIVERED,
|
||||
NOTIFICATION_SENDING,
|
||||
NOTIFICATION_TEMPORARY_FAILURE,
|
||||
NOTIFICATION_TECHNICAL_FAILURE,
|
||||
SMS_TYPE,
|
||||
)
|
||||
@@ -476,7 +477,7 @@ def update_letter_notifications_statuses(self, filename):
|
||||
else:
|
||||
for update in notification_updates:
|
||||
status = NOTIFICATION_DELIVERED if update.status == DVLA_RESPONSE_STATUS_SENT \
|
||||
else NOTIFICATION_TECHNICAL_FAILURE
|
||||
else NOTIFICATION_TEMPORARY_FAILURE
|
||||
updated_count = dao_update_notifications_by_reference(
|
||||
references=[update.reference],
|
||||
update_dict={"status": status,
|
||||
|
||||
Reference in New Issue
Block a user