mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-18 13:39:41 -04:00
fix contact list bst bug
the api returns UTC timestamps, we should keep them as UTC timestamps until the very last moment, and only convert them into BST when we know we want to return to a user (ie: in contact-list.html and other places like that)
This commit is contained in:
@@ -4,7 +4,6 @@ from os import path
|
||||
from flask import abort, current_app
|
||||
from notifications_utils.formatters import strip_whitespace
|
||||
from notifications_utils.recipients import RecipientCSV
|
||||
from notifications_utils.timezones import utc_string_to_aware_gmt_datetime
|
||||
from werkzeug.utils import cached_property
|
||||
|
||||
from app.models import JSONModel, ModelList
|
||||
@@ -23,6 +22,7 @@ class ContactList(JSONModel):
|
||||
|
||||
ALLOWED_PROPERTIES = {
|
||||
'id',
|
||||
'created_at',
|
||||
'created_by',
|
||||
'has_jobs',
|
||||
'recent_job_count',
|
||||
@@ -115,10 +115,6 @@ class ContactList(JSONModel):
|
||||
contact_list_id=self.id,
|
||||
)
|
||||
|
||||
@property
|
||||
def created_at(self):
|
||||
return utc_string_to_aware_gmt_datetime(self._dict['created_at'])
|
||||
|
||||
@property
|
||||
def contents(self):
|
||||
return self.download(self.service_id, self.id)
|
||||
|
||||
Reference in New Issue
Block a user