summaryrefslogtreecommitdiff
path: root/app/assets/javascripts/admin/users
diff options
context:
space:
mode:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-03-16 18:18:33 +0000
committerGitLab Bot <gitlab-bot@gitlab.com>2021-03-16 18:18:33 +0000
commitf64a639bcfa1fc2bc89ca7db268f594306edfd7c (patch)
treea2c3c2ebcc3b45e596949db485d6ed18ffaacfa1 /app/assets/javascripts/admin/users
parentbfbc3e0d6583ea1a91f627528bedc3d65ba4b10f (diff)
downloadgitlab-ce-f64a639bcfa1fc2bc89ca7db268f594306edfd7c.tar.gz
Add latest changes from gitlab-org/gitlab@13-10-stable-eev13.10.0-rc40
Diffstat (limited to 'app/assets/javascripts/admin/users')
-rw-r--r--app/assets/javascripts/admin/users/tabs.js11
1 files changed, 10 insertions, 1 deletions
diff --git a/app/assets/javascripts/admin/users/tabs.js b/app/assets/javascripts/admin/users/tabs.js
index 9ada77396c7..cbaab7df4e9 100644
--- a/app/assets/javascripts/admin/users/tabs.js
+++ b/app/assets/javascripts/admin/users/tabs.js
@@ -1,11 +1,20 @@
+import Api from '~/api';
import { historyPushState } from '~/lib/utils/common_utils';
import { mergeUrlParams } from '~/lib/utils/url_utility';
const COHORTS_PANE = 'cohorts';
+const COHORTS_PANE_TAB_CLICK_EVENT = 'i_analytics_cohorts';
const tabClickHandler = (e) => {
const { hash } = e.currentTarget;
- const tab = hash === `#${COHORTS_PANE}` ? COHORTS_PANE : null;
+
+ let tab = null;
+
+ if (hash === `#${COHORTS_PANE}`) {
+ tab = COHORTS_PANE;
+ Api.trackRedisHllUserEvent(COHORTS_PANE_TAB_CLICK_EVENT);
+ }
+
const newUrl = mergeUrlParams({ tab }, window.location.href);
historyPushState(newUrl);
};