Make technical failure letters show up on the activity page

This commit is contained in:
Chris Hill-Scott
2019-01-10 17:23:03 +00:00
parent 55279c91b5
commit 989875294b
3 changed files with 20 additions and 19 deletions

View File

@@ -362,18 +362,20 @@ def format_notification_status(status, template_type):
'sent': 'Sent internationally'
},
'letter': {
'failed': 'Failed',
'failed': '',
'technical-failure': 'Technical failure',
'temporary-failure': 'Temporary failure',
'permanent-failure': 'Permanent failure',
'delivered': 'Delivered',
'sending': 'Sending',
'created': 'Sending',
'sent': 'Delivered',
'pending-virus-check': 'Pending virus check',
'temporary-failure': '',
'permanent-failure': 'Cancelled',
'delivered': '',
'received': '',
'accepted': '',
'sending': '',
'created': '',
'sent': '',
'pending-virus-check': '',
'virus-scan-failed': 'Virus detected',
'returned-letter': 'Delivered',
'cancelled': 'Cancelled,',
'returned-letter': '',
'cancelled': '',
'validation-failed': 'Validation failed',
}
}[template_type].get(status, status)