From 125a7a9daf6f40470f27bbe7cdc3d0a5aea4764c Mon Sep 17 00:00:00 2001 From: Bethuel Mmbaga Date: Tue, 7 Nov 2023 14:05:58 +0300 Subject: [PATCH] Add integration activity types to codes.go (#1293) New activity types for integration creation, update, and deletion have been added to the activity codes. This ensures the tracking of these user activities relating to integrations, which were not previously being logged. --- management/server/activity/codes.go | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/management/server/activity/codes.go b/management/server/activity/codes.go index ce36f520f..7bad9f627 100644 --- a/management/server/activity/codes.go +++ b/management/server/activity/codes.go @@ -114,6 +114,12 @@ const ( PeerLoginExpired // DashboardLogin indicates that the user logged in to the dashboard DashboardLogin + // IntegrationCreated indicates that the user created an integration + IntegrationCreated + // IntegrationUpdated indicates that the user updated an integration + IntegrationUpdated + // IntegrationDeleted indicates that the user deleted an integration + IntegrationDeleted ) var activityMap = map[Activity]Code{ @@ -169,6 +175,9 @@ var activityMap = map[Activity]Code{ UserLoggedInPeer: {"User logged in peer", "user.peer.login"}, PeerLoginExpired: {"Peer login expired", "peer.login.expire"}, DashboardLogin: {"Dashboard login", "dashboard.login"}, + IntegrationCreated: {"Integration created", "integration.create"}, + IntegrationUpdated: {"Integration updated", "integration.update"}, + IntegrationDeleted: {"Integration deleted", "integration.delete"}, } // StringCode returns a string code of the activity