Skip to content

Commit 50b170f

Browse files
authored
Merge branch 'next' into QT-232
2 parents fab4b32 + 67a9010 commit 50b170f

File tree

7 files changed

+109
-8
lines changed

7 files changed

+109
-8
lines changed

api/parts/data/fetch.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1323,7 +1323,7 @@ fetch.fetchEvents = function(params) {
13231323
*/
13241324
fetch.fetchTimeObj = function(collection, params, isCustomEvent, options) {
13251325
fetchTimeObj(collection, params, isCustomEvent, options, function(output) {
1326-
if (params?.qstring?.event) {
1326+
if (params.qstring?.event) {
13271327
output.eventName = params.qstring.event;
13281328
}
13291329
common.returnOutput(params, output);

frontend/express/public/core/events/javascripts/countly.details.models.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1081,7 +1081,7 @@
10811081
.then(function(resp) {
10821082
if (resp) {
10831083
context.commit("setSelectedEventsOverview", countlyAllEvents.helpers.getSelectedEventsOverview(context, resp) || {});
1084-
context.commit("setLegendData", countlyAllEvents.helpers.getLegendData(context || {}));
1084+
context.commit("setLegendData", countlyAllEvents.helpers.getLegendData(context));
10851085
}
10861086
});
10871087
}

frontend/express/public/core/events/javascripts/countly.overview.models.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,9 @@
107107
return monitorData;
108108
},
109109
getOverviewConfigureList: function(eventsList, groupList) {
110-
var map = eventsList.map || {};
111110
var allEvents = [];
112111
if (eventsList && eventsList.list) {
112+
var map = eventsList.map || {};
113113
eventsList.list.forEach(function(item) {
114114
if (!map[item] || (map[item] && (map[item].is_visible || map[item].is_visible === undefined))) {
115115
var label;
@@ -141,9 +141,9 @@
141141
return allEvents;
142142
},
143143
getEventMapping: function(eventsList, groupList) {
144-
var map = eventsList.map || {};
145144
var mapping = {};
146145
if (eventsList && eventsList.list) {
146+
var map = eventsList.map || {};
147147
eventsList.list.forEach(function(item) {
148148
var obj = {
149149
"eventKey": item,

plugins/alerts/frontend/public/javascripts/countly.views.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -992,10 +992,10 @@
992992

993993

994994
if (newState.alertBy === "email") {
995-
if (newState?.allGroups?.length) {
995+
if (newState.allGroups?.length) {
996996
this.selectedRadioButton = "toGroup";
997997
}
998-
if (newState?.alertValues?.length) {
998+
if (newState.alertValues?.length) {
999999
this.selectedRadioButton = "specificAddress";
10001000
}
10011001
}

plugins/compare/frontend/public/javascripts/countly.models.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -201,9 +201,9 @@
201201
return lineLegend;
202202
},
203203
getAllEventsList: function(eventsList, groupList) {
204-
var map = eventsList.map || {};
205204
var allEvents = [];
206205
if (eventsList) {
206+
var map = eventsList.map || {};
207207
eventsList.list.forEach(function(item) {
208208
if (!map[item] || (map[item] && (map[item].is_visible || map[item].is_visible === undefined))) {
209209
var label;
@@ -245,9 +245,9 @@
245245
return obj;
246246
},
247247
getTableStateMap: function(eventsList, groupList) {
248-
var map = eventsList.map || {};
249248
var allEvents = {};
250249
if (eventsList) {
250+
var map = eventsList.map || {};
251251
eventsList.list.forEach(function(item) {
252252
if (!map[item] || (map[item] && (map[item].is_visible || map[item].is_visible === undefined))) {
253253
allEvents[countlyCompareEvents.helpers.decode(item)] = true;

plugins/hooks/README.md

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,3 +62,73 @@ hooks/ # Main hooks plugin directory
6262
```bash
6363
npm install
6464
```
65+
66+
## Using Hooks
67+
68+
First, ensure that Hooks is enabled. In the Sidebar, navigate to Management > Feature Management and switch on the Hooks toggle.
69+
70+
## Creating a New Hook
71+
72+
To create a new Hook in the Countly Hooks Plugin, follow these steps:
73+
74+
### Step 1: Start a New Hook
75+
76+
- Click on the **+ New Hook** button located in the top right corner of the default view. A new drawer will open where you’ll need to fill out the following fields.
77+
78+
### Step 2: Fill in Hook Details
79+
80+
1. **Hook Name**: Enter a concise and descriptive name for your Hook. This field is required and should adhere to SDK naming limitations.
81+
2. **Description** (optional): Provide a brief explanation of the Hook’s purpose. This can help your colleagues understand why it was created. Avoid long descriptions and special characters.
82+
3. **Source App**: Select the application where the Hook will apply. You can use the search bar to find your app, but only one app can be chosen per Hook. Click on **Next Step** to proceed to trigger selection.
83+
84+
### Step 3: Select the Trigger Type
85+
86+
From the dropdown, choose a trigger type for your Hook. Options include:
87+
88+
- **Tracked Data**
89+
- **Internal Actions**
90+
- **API Endpoint**
91+
92+
#### For Tracked Data
93+
94+
- Choose a specific data point from the list or dropdown.
95+
- Set a filtering rule if needed; you may add multiple conditions.
96+
97+
#### For Internal Actions
98+
99+
- Select a trigger from the dropdown.
100+
- Depending on the chosen trigger, specify the details using the subsequent dropdown (e.g., select a specific cohort from the list).
101+
102+
#### For API Endpoint
103+
104+
- Choose a trigger from the dropdown.
105+
- Specify further using the new dropdown that appears (e.g., select a cohort).
106+
107+
### Step 4: Set up a Recurring Trigger (Optional)
108+
109+
Select one of the following frequencies for the trigger:
110+
111+
- **Every hour** (includes time zone selection)
112+
- **Every day** (includes time zone selection)
113+
- **Every week** (select day of the week, hour, and time zone)
114+
- **Every month** (select day of the month from 1 to 28, hour, and time zone)
115+
116+
Then, specify when the trigger should run.
117+
118+
### Step 5: Choose an Action Type
119+
120+
Choose an action from the dropdown options:
121+
122+
- **Send Email**
123+
- **Make HTTP Request**
124+
- **Custom Code**
125+
126+
You can add multiple actions by clicking **Add Action**.
127+
128+
### Step 6: Test the Hook (Optional)
129+
130+
- To verify if the Hook functions as expected, click the **Test the Hook** button. For further guidance, refer to the “Testing a Hook” section below.
131+
132+
### Step 7: Save the Hook
133+
134+
After completing all fields, click **Save**. A success message will confirm that your Hook has been saved successfully.

plugins/times-of-day/README.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -54,3 +54,34 @@ times-of-day/
5454
```bash
5555
npm install
5656
```
57+
58+
## Using Times of Day
59+
60+
The Times of Day feature allows you to analyze user activity based on specific time criteria. Follow these steps to effectively use this tool.
61+
62+
### Step 1: Selecting Criteria
63+
64+
- **Criteria Options**: Start by selecting a criteria from the **Dropdown Menu** at the top left. Available options include:
65+
- **Sessions**
66+
- **Events**
67+
- **Consent**
68+
- **Push Action**
69+
70+
- **Time Period**: Use the **Dropdown Menu** at the top right to specify a time range. This will automatically refresh the data chart and data table with the relevant activity details.
71+
72+
### Step 2: Understanding the Data Chart
73+
74+
- The **Data Chart** shows activity by **hour of the day** (in 24-hour format on the x-axis) and **day of the week** (on the y-axis).
75+
- **Colored circles** represent activity levels at each time and day intersection. The larger the circle, the higher the number of users.
76+
- You can download this chart as a **PNG image** by clicking the **Downward Arrow** button at the top right of the chart.
77+
78+
### Step 3: Understanding the Data Table
79+
80+
- Below the Data Chart is the **Data Table**, which provides the information in a detailed, tabular format with specific user counts.
81+
- The table includes:
82+
- **Hours**: Each hour of the day, in hourly segments.
83+
- **Days**: Columns for each day of the week showing the active user count per hour.
84+
85+
- You can export the table in **CSV, JSON, or XLSX** format by clicking the **Downward Arrow** button at the top right of the table.
86+
87+
This feature is ideal for visualizing and exporting user activity based on selected criteria and time frames for further analysis.

0 commit comments

Comments
 (0)