mirror of
https://github.com/GSA/notifications-admin.git
synced 2026-09-11 10:28:41 -04:00
Add an event if a user is archived
This adds a new type of event, 'archive_user', which stores the id of the archived user and the id of the user who is doing the archiving.
This commit is contained in:
@@ -25,6 +25,13 @@ def create_mobile_number_change_event(user_id, updated_by_id, original_mobile_nu
|
||||
new_mobile_number=new_mobile_number)
|
||||
|
||||
|
||||
def create_archive_user_event(user_id, archived_by_id):
|
||||
_send_event(
|
||||
'archive_user',
|
||||
user_id=user_id,
|
||||
archived_by_id=archived_by_id)
|
||||
|
||||
|
||||
def _send_event(event_type, **kwargs):
|
||||
event_data = _construct_event_data(request)
|
||||
event_data.update(kwargs)
|
||||
|
||||
Reference in New Issue
Block a user