mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-08 07:48:26 -04:00
Improve display of failure rates
https://www.pivotaltracker.com/story/show/116052359 - add absolute numbers for failures - make percentages accurate to 1 decimal place (50.0%) - make error colour appear if failures go above 3.0% - make error colour boolean (don’t interpolate between the colours)
This commit is contained in:
@@ -8,18 +8,18 @@
|
||||
{{ big_number_with_status(
|
||||
statistics.get('emails_requested', 0),
|
||||
'email' if statistics.get('emails_requested') == 1 else 'emails',
|
||||
'{}%'.format(statistics.get('emails_failure_rate', 0)),
|
||||
'failed',
|
||||
statistics.get('emails_percentage_of_danger_zone', 0)
|
||||
statistics.get('emails_error'),
|
||||
statistics.get('emails_failure_rate', 0.0),
|
||||
statistics.get('emails_failure_rate', 0)|float > 3
|
||||
) }}
|
||||
</div>
|
||||
<div class="column-half">
|
||||
{{ big_number_with_status(
|
||||
statistics.get('sms_requested', 0),
|
||||
'text message' if statistics.get('sms_requested') == 1 else 'text messages',
|
||||
'{}%'.format(statistics.get('sms_failure_rate', 0)),
|
||||
'failed',
|
||||
statistics.get('sms_percentage_of_danger_zone', 0)
|
||||
statistics.get('sms_error'),
|
||||
statistics.get('sms_failure_rate', 0.0),
|
||||
statistics.get('sms_failure_rate', 0)|float > 3
|
||||
) }}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user