mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-08-19 05:59:44 -04:00
Audit when a service is archived ("deleted")
This is similar to the previous commit. I've used the term 'archive' to match the rest of the code - services aren't ever truly deleted.
This commit is contained in:
@@ -29,6 +29,7 @@ from app import (
|
||||
user_api_client,
|
||||
)
|
||||
from app.event_handlers import (
|
||||
create_archive_service_event,
|
||||
create_broadcast_account_type_change_event,
|
||||
create_suspend_service_event,
|
||||
)
|
||||
@@ -428,6 +429,8 @@ def archive_service(service_id):
|
||||
cached_service_user_ids = [user.id for user in current_service.active_users]
|
||||
|
||||
service_api_client.archive_service(service_id, cached_service_user_ids)
|
||||
create_archive_service_event(service_id, archived_by_id=current_user.id)
|
||||
|
||||
flash(
|
||||
'‘{}’ was deleted'.format(current_service.name),
|
||||
'default_with_tick',
|
||||
|
||||
Reference in New Issue
Block a user