mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-02-06 03:13:42 -05:00
Make SMS rate a constant
Now that it doesn’t depend on any logic it doesn’t need to be a function.
This commit is contained in:
@@ -13,7 +13,7 @@ from notifications_utils.template import HTMLEmailTemplate, LetterImageTemplate
|
||||
from app import email_branding_client, letter_branding_client, status_api_client
|
||||
from app.main import main
|
||||
from app.main.forms import FieldWithNoneOption
|
||||
from app.main.views.pricing import get_current_sms_rate
|
||||
from app.main.views.pricing import SMS_RATE
|
||||
from app.main.views.sub_navigation_dictionaries import (
|
||||
features_nav,
|
||||
using_notify_nav,
|
||||
@@ -29,7 +29,7 @@ def index():
|
||||
|
||||
return render_template(
|
||||
'views/signedout.html',
|
||||
sms_rate=get_current_sms_rate(),
|
||||
sms_rate=SMS_RATE,
|
||||
counts=status_api_client.get_count_of_live_services_and_organisations(),
|
||||
)
|
||||
|
||||
|
||||
@@ -1,26 +1,22 @@
|
||||
from datetime import datetime
|
||||
|
||||
from flask import current_app, render_template
|
||||
from flask_login import current_user
|
||||
from notifications_utils.international_billing_rates import (
|
||||
INTERNATIONAL_BILLING_RATES,
|
||||
)
|
||||
from notifications_utils.timezones import convert_utc_to_bst
|
||||
|
||||
from app.main import main
|
||||
from app.main.forms import SearchByNameForm
|
||||
from app.main.views.sub_navigation_dictionaries import pricing_nav
|
||||
|
||||
|
||||
def get_current_sms_rate():
|
||||
return '1.72'
|
||||
SMS_RATE = '1.72'
|
||||
|
||||
|
||||
@main.route('/pricing')
|
||||
def pricing():
|
||||
return render_template(
|
||||
'views/pricing/index.html',
|
||||
sms_rate=get_current_sms_rate(),
|
||||
sms_rate=SMS_RATE,
|
||||
international_sms_rates=sorted([
|
||||
(cc, country['names'], country['billable_units'])
|
||||
for cc, country in INTERNATIONAL_BILLING_RATES.items()
|
||||
|
||||
Reference in New Issue
Block a user