Use new "cost" field in usage APIs

The previous, manual calculation could be incorrect depending on
which SMS rates the free allowance was attributed to.

The new field also supersedes the old "letter_total" bolt-on so we
can get cost information consistently for both types.
This commit is contained in:
Ben Thorner
2022-04-26 15:40:29 +01:00
parent 82c3e8093d
commit e0aa51c306
5 changed files with 14 additions and 12 deletions

View File

@@ -59,7 +59,7 @@
<div class='govuk-grid-column-one-third'>
<div class="keyline-block">
{{ big_number(
(sms_chargeable * sms_rate),
sms_cost,
'spent',
currency="£",
smaller=True