mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-23 15:57:23 -04:00
Merge branch 'master' into delete-letter-job-page
This commit is contained in:
@@ -423,10 +423,7 @@ ashbournetowncouncil.gov.uk:
|
||||
owner: Ashbourne Town Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
ashfield-dc.gov.uk:
|
||||
owner: Ashfield District Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
ashfield-dc.gov.uk: ashfield.gov.uk
|
||||
ashfield.gov.uk:
|
||||
owner: Ashfield District Council
|
||||
crown: false
|
||||
@@ -1537,7 +1534,7 @@ dorchester-tc.gov.uk:
|
||||
dorsetcc.gov.uk:
|
||||
owner: Dorset County Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
agreement_signed: true
|
||||
dorsetforyou.gov.uk:
|
||||
owner: Weymouth and Portland Borough Council
|
||||
crown: false
|
||||
@@ -3715,7 +3712,7 @@ rosstc-herefordshire.gov.uk:
|
||||
rother.gov.uk:
|
||||
owner: Rother District Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
agreement_signed: true
|
||||
rotherham.gov.uk:
|
||||
owner: Rotherham Borough Council
|
||||
crown: false
|
||||
@@ -5120,15 +5117,9 @@ worcester.gov.uk:
|
||||
worcestershire.gov.uk:
|
||||
owner: Worcestershire County Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
worcestershirehub.gov.uk:
|
||||
owner: Worcestershire County Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
worcestershirets.gov.uk:
|
||||
owner: Worcestershire County Council
|
||||
crown: false
|
||||
agreement_signed: false
|
||||
agreement_signed: true
|
||||
worcestershirehub.gov.uk: worcestershire.gov.uk
|
||||
worcestershirets.gov.uk: worcestershire.gov.uk
|
||||
worcsregservices.gov.uk:
|
||||
owner: Bromsgrove District Council
|
||||
crown: false
|
||||
|
||||
@@ -216,10 +216,12 @@ def get_notifications(service_id, message_type, status_override=None):
|
||||
abort(404)
|
||||
filter_args = parse_filter_args(request.args)
|
||||
filter_args['status'] = set_status_filters(filter_args)
|
||||
service_data_retention_days = None
|
||||
|
||||
service_data_retention_days = service_api_client.get_service_data_retention_by_notification_type(
|
||||
service_id, message_type
|
||||
).get('days_of_retention', current_app.config['ACTIVITY_STATS_LIMIT_DAYS'])
|
||||
if message_type is not None:
|
||||
service_data_retention_days = service_api_client.get_service_data_retention_by_notification_type(
|
||||
service_id, message_type
|
||||
).get('days_of_retention', current_app.config['ACTIVITY_STATS_LIMIT_DAYS'])
|
||||
|
||||
if request.path.endswith('csv') and current_user.has_permissions('view_activity'):
|
||||
return Response(
|
||||
|
||||
@@ -58,6 +58,12 @@ class Service():
|
||||
return self._dict[attr]
|
||||
raise AttributeError('`{}` is not a service attribute'.format(attr))
|
||||
|
||||
def _get_by_id(self, things, id):
|
||||
try:
|
||||
return next(thing for thing in things if thing['id'] == id)
|
||||
except StopIteration:
|
||||
abort(404)
|
||||
|
||||
def update(self, **kwargs):
|
||||
return service_api_client.update_service(self.id, **kwargs)
|
||||
|
||||
@@ -310,13 +316,7 @@ class Service():
|
||||
]
|
||||
|
||||
def get_template_folder(self, folder_id):
|
||||
try:
|
||||
return next(
|
||||
folder for folder in self.all_template_folders
|
||||
if folder['id'] == folder_id
|
||||
)
|
||||
except StopIteration:
|
||||
abort(404)
|
||||
return self._get_by_id(self.all_template_folders, folder_id)
|
||||
|
||||
def is_folder_visible(self, template_folder_id, template_type='all'):
|
||||
|
||||
@@ -374,7 +374,4 @@ class Service():
|
||||
)
|
||||
|
||||
def get_api_key(self, id):
|
||||
try:
|
||||
return next(key for key in self.api_keys if key['id'] == id)
|
||||
except StopIteration:
|
||||
abort(404)
|
||||
return self._get_by_id(self.api_keys, id)
|
||||
|
||||
Reference in New Issue
Block a user