Don’t show status for individual letters

The status won’t ever change from sending for letters. For now at least.
And even when we do come up with more useful statuses I’m not convinced
it’s useful to expose them to our admin users.

A more useful piece of information to show is when we think the letter
will be delivered.
This commit is contained in:
Chris Hill-Scott
2017-07-13 13:05:41 +01:00
parent b003162932
commit 63e9ef44e7
5 changed files with 45 additions and 6 deletions

View File

@@ -86,7 +86,7 @@ def service_json(
def template_json(service_id,
id_,
name="sample template",
type_="sms",
type_=None,
content=None,
subject=None,
version=1,
@@ -97,7 +97,7 @@ def template_json(service_id,
template = {
'id': id_,
'name': name,
'template_type': type_,
'template_type': type_ or "sms",
'content': content,
'service': service_id,
'version': version,
@@ -226,9 +226,10 @@ def notification_json(
with_links=False,
rows=5,
personalisation=None,
template_type=None,
):
if template is None:
template = template_json(service_id, str(generate_uuid()))
template = template_json(service_id, str(generate_uuid()), type_=template_type)
if sent_at is None:
sent_at = str(datetime.utcnow().time())
if created_at is None: