Browse Source

Fix and update help pages for notification templates

pull/8423/head
ViacheslavKlimov 3 years ago
parent
commit
80cfd89421
  1. 11
      ui-ngx/src/app/shared/models/notification.models.ts
  2. 43
      ui-ngx/src/assets/help/en_US/notification/alarm.md
  3. 59
      ui-ngx/src/assets/help/en_US/notification/alarm_assignment.md
  4. 53
      ui-ngx/src/assets/help/en_US/notification/alarm_comment.md
  5. 40
      ui-ngx/src/assets/help/en_US/notification/api_usage_limit.md
  6. 39
      ui-ngx/src/assets/help/en_US/notification/device_activity.md
  7. 36
      ui-ngx/src/assets/help/en_US/notification/entities_limit.md
  8. 48
      ui-ngx/src/assets/help/en_US/notification/entity_action.md
  9. 19
      ui-ngx/src/assets/help/en_US/notification/general.md
  10. 31
      ui-ngx/src/assets/help/en_US/notification/new_platform_version.md
  11. 54
      ui-ngx/src/assets/help/en_US/notification/rule_engine.md
  12. 37
      ui-ngx/src/assets/help/en_US/notification/rule_engine_lifecycle_event.md
  13. 57
      ui-ngx/src/assets/help/en_US/notification/rule_node.md

11
ui-ngx/src/app/shared/models/notification.models.ts

@ -101,9 +101,10 @@ interface SlackNotificationDeliveryMethodConfig {
export interface SlackConversation { export interface SlackConversation {
id: string; id: string;
title: string; title: string;
shortName: string; name: string;
wholeName: string; wholeName: string;
email: string; email: string;
type: string;
} }
export interface NotificationRule extends Omit<BaseData<NotificationRuleId>, 'label'>{ export interface NotificationRule extends Omit<BaseData<NotificationRuleId>, 'label'>{
@ -443,7 +444,7 @@ export enum NotificationType {
ENTITIES_LIMIT = 'ENTITIES_LIMIT', ENTITIES_LIMIT = 'ENTITIES_LIMIT',
API_USAGE_LIMIT = 'API_USAGE_LIMIT', API_USAGE_LIMIT = 'API_USAGE_LIMIT',
NEW_PLATFORM_VERSION = 'NEW_PLATFORM_VERSION', NEW_PLATFORM_VERSION = 'NEW_PLATFORM_VERSION',
RULE_ENGINE = 'RULE_ENGINE' RULE_NODE = 'RULE_NODE'
} }
export const NotificationTypeIcons = new Map<NotificationType, string | null>([ export const NotificationTypeIcons = new Map<NotificationType, string | null>([
@ -543,10 +544,10 @@ export const NotificationTemplateTypeTranslateMap = new Map<NotificationType, No
helpId: 'notification/new_platform_version' helpId: 'notification/new_platform_version'
} }
], ],
[NotificationType.RULE_ENGINE, [NotificationType.RULE_NODE,
{ {
name: 'notification.template-type.rule-engine', name: 'notification.template-type.rule-node',
helpId: 'notification/rule_engine' helpId: 'notification/rule_node'
} }
] ]
]); ]);

43
ui-ngx/src/assets/help/en_US/notification/alarm.md

@ -3,35 +3,38 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `alarmType` - alarm type;
* *recipientFirstName* - first name of the recipient; * `action` - one of: 'created', 'severity changed', 'acknowledged', 'cleared', 'deleted';
* *recipientLastName* - last name of the recipient; * `alarmId` - the alarm id as uuid string;
* *alarmType* - alarm type; * `alarmSeverity` - alarm severity (lower case);
* *action* - one of: 'created', 'severity changed', 'acknowledged', 'cleared', 'deleted'; * `alarmStatus` - the alarm status;
* *alarmId* - the alarm id as uuid string; * `alarmOriginatorEntityType` - the entity type of the alarm originator, e.g. 'Device';
* *alarmSeverity* - alarm severity (lower case); * `alarmOriginatorName` - the name of the alarm originator, e.g. 'Sensor T1';
* *alarmStatus* - the alarm status; * `alarmOriginatorId` - the alarm originator entity id as uuid string;
* *alarmOriginatorEntityType* - the entity type of the alarm originator, e.g. 'Device'; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *alarmOriginatorName* - the name of the alarm originator, e.g. 'Sensor T1'; * `recipientEmail` - email of the recipient;
* *alarmOriginatorId* - the alarm originator entity id as uuid string; * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${action}`.
Parameter names must be wrapped using `${...}`. For example: `${action}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
* Let's assume the notification about new alarm with type 'High Temperature' for device 'Sensor A'. The following template: Let's assume the notification about new alarm with type 'High Temperature' for device 'Sensor A'.
The following template:
```text ```text
Alarm '${alarmType}' - ${action:upperCase} Alarm '${alarmType}' - ${action:upperCase}
@ -42,9 +45,10 @@ will be transformed to:
```text ```text
Alarm 'High Temperature' - CREATED Alarm 'High Temperature' - CREATED
{:copy-code}
``` ```
<br/>
The following template: The following template:
```text ```text
@ -56,7 +60,6 @@ will be transformed to:
```text ```text
Device - Sensor A Device - Sensor A
{:copy-code}
``` ```
<br> <br>

59
ui-ngx/src/assets/help/en_US/notification/alarm_assignment.md

@ -3,42 +3,47 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `alarmType` - alarm type;
* *recipientFirstName* - first name of the recipient; * `alarmId` - the alarm id as uuid string;
* *recipientLastName* - last name of the recipient; * `alarmSeverity` - alarm severity (lower case);
* *alarmType* - alarm type; * `alarmStatus` - the alarm status;
* *alarmId* - the alarm id as uuid string; * `alarmOriginatorEntityType` - the entity type of the alarm originator, e.g. 'Device';
* *alarmSeverity* - alarm severity (lower case); * `alarmOriginatorName` - the name of the alarm originator, e.g. 'Sensor T1';
* *alarmStatus* - the alarm status; * `alarmOriginatorId` - the alarm originator entity id as uuid string;
* *alarmOriginatorEntityType* - the entity type of the alarm originator, e.g. 'Device'; * `assigneeTitle` - title of the assignee;
* *alarmOriginatorName* - the name of the alarm originator, e.g. 'Sensor T1'; * `assigneeEmail` - email of the assignee;
* *alarmOriginatorId* - the alarm originator entity id as uuid string; * `assigneeFirstName` - first name of the assignee;
* *assigneeEmail* - email of the assignee; * `assigneeLastName` - last name of the assignee;
* *assigneeFirstName* - first name of the assignee; * `assigneeId` - the id of the assignee as uuid string;
* *assigneeLastName* - last name of the assignee; * `userTitle` - title of the user who made the action;
* *assigneeId* - the id of the assignee as uuid string; * `userEmail` - email of the user who made the action;
* *userEmail* - email of the user who made the action; * `userFirstName` - first name of the user who made the action;
* *userFirstName* - first name of the user who made the action; * `userLastName` - last name of the user who made the action;
* *userLastName* - last name of the user who made the action; * `action` - one of: 'assigned', 'unassigned';
* *action* - one of: 'assigned', 'unassigned'; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* `recipientEmail` - email of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${action}`. * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${action}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
* Let's assume the notification about alarm with type 'High Temperature' for device 'Sensor A' was assigned to user 'John Doe'. The following template: Let's assume the notification about alarm with type 'High Temperature' for device 'Sensor A' was assigned
to user 'John Doe'. The following template:
```text ```text
Alarm '${alarmType}' - ${action:upperCase} Alarm '${alarmType}' - ${action:upperCase}
@ -49,9 +54,10 @@ will be transformed to:
```text ```text
Alarm 'High Temperature' - ASSIGNED Alarm 'High Temperature' - ASSIGNED
{:copy-code}
``` ```
<br/>
The following template: The following template:
```text ```text
@ -63,7 +69,6 @@ will be transformed to:
```text ```text
Alarm 'High Temperature' (Critical) was assigned to user Alarm 'High Temperature' (Critical) was assigned to user
{:copy-code}
``` ```
<br> <br>

53
ui-ngx/src/assets/help/en_US/notification/alarm_comment.md

@ -3,40 +3,43 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `alarmType` - alarm type;
* *recipientFirstName* - first name of the recipient; * `alarmId` - the alarm id as uuid string;
* *recipientLastName* - last name of the recipient; * `alarmSeverity` - alarm severity (lower case);
* *alarmType* - alarm type; * `alarmStatus` - the alarm status;
* *alarmId* - the alarm id as uuid string; * `alarmOriginatorEntityType` - the entity type of the alarm originator, e.g. 'Device';
* *alarmSeverity* - alarm severity (lower case); * `alarmOriginatorName` - the name of the alarm originator, e.g. 'Sensor T1';
* *alarmStatus* - the alarm status; * `alarmOriginatorId` - the alarm originator entity id as uuid string;
* *alarmOriginatorEntityType* - the entity type of the alarm originator, e.g. 'Device'; * `comment` - text of the comment;
* *alarmOriginatorName* - the name of the alarm originator, e.g. 'Sensor T1'; * `action` - one of: 'added', 'updated';
* *alarmOriginatorId* - the alarm originator entity id as uuid string; * `userTitle` - title of the user who made the action;
* *comment* - text of the comment; * `userEmail` - email of the user who made the action;
* *action* - one of: 'added', 'updated'; * `userFirstName` - first name of the user who made the action;
* *userEmail* - email of the user who made the action; * `userLastName` - last name of the user who made the action;
* *userFirstName* - first name of the user who made the action; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *userLastName* - last name of the user who made the action; * `recipientEmail` - email of the recipient;
* `recipientFirstName` - first name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${action}`. * `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${action}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
* Let's assume the notification about alarm with type 'High Temperature' for device 'Sensor A' was assigned to user 'John Doe'. Let's assume the notification about alarm with type 'High Temperature' for device 'Sensor A' was assigned
The following template: to user 'John Doe'. The following template:
```text ```text
Alarm '${alarmType}' - comment ${action} Alarm '${alarmType}' - comment ${action}
@ -47,9 +50,10 @@ will be transformed to:
```text ```text
Alarm 'High Temperature' - comment added Alarm 'High Temperature' - comment added
{:copy-code}
``` ```
<br/>
The following template: The following template:
```text ```text
@ -61,7 +65,6 @@ will be transformed to:
```text ```text
Alarm 'High Temperature' (Critical) was commented Alarm 'High Temperature' (Critical) was commented
{:copy-code}
``` ```
<br> <br>

40
ui-ngx/src/assets/help/en_US/notification/api_usage_limit.md

@ -3,34 +3,39 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `feature` - API feature for which the limit is applied; one of: 'Device API', 'Telemetry persistence',
* *recipientFirstName* - first name of the recipient; 'Rule Engine execution', 'JavaScript functions execution', 'Email messages', 'SMS messages', 'Alarms';
* *recipientLastName* - last name of the recipient; * `status` - one of: 'enabled', 'warning', 'disabled';
* *feature* - API feature for which the limit is applied; one of: 'Device API', 'Telemetry persistence', 'Rule Engine execution', 'JavaScript functions execution', 'Email messages', 'SMS messages', 'Alarms'; * `unitLabel` - name of the limited unit; one of: 'message', 'data point', 'Rule Engine execution',
* *status* - one of: 'enabled', 'warning', 'disabled'; 'JavaScript execution', 'email message', 'SMS message', 'alarm';
* *unitLabel* - name of the limited unit; one of: 'message', 'data point', 'Rule Engine execution', 'JavaScript execution', 'email message', 'SMS message', 'alarm'; * `limit` - the limit on used feature units;
* *limit* - the limit on used feature units; * `currentValue` - current number of used units;
* *currentValue* - current number of used units; * `tenantId` - id of the tenant;
* *tenantId* - id of the tenant; * `tenantName` - name of the tenant;
* *tenantName* - name of the tenant; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* `recipientEmail` - email of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`. * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
Let's assume tenant's devices pushed 8K messages with the max allowed number of 10K and warn threshold in tenant profile set to 0.8 (80%). The following template: Let's assume tenant's devices pushed 8K messages with the max allowed number of 10K
and warn threshold in tenant profile set to 0.8 (80%). The following template:
```text ```text
${feature} feature - ${status:upperCase} (usage: ${currentValue} out of ${limit} ${unitLabel}s) ${feature} feature - ${status:upperCase} (usage: ${currentValue} out of ${limit} ${unitLabel}s)
@ -41,7 +46,6 @@ will be transformed to:
```text ```text
Device API feature - WARNING (usage: 8000 out of 10000 messages) Device API feature - WARNING (usage: 8000 out of 10000 messages)
{:copy-code}
``` ```
<br> <br>

39
ui-ngx/src/assets/help/en_US/notification/device_activity.md

@ -3,36 +3,36 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `deviceId` - the device id as uuid string;
* *recipientFirstName* - first name of the recipient; * `deviceName` - the device name;
* *recipientLastName* - last name of the recipient; * `deviceLabel` - the device label;
* *deviceId* - the device id as uuid string; * `deviceType` - the device type;
* *deviceName* - the device name; * `eventType` - one of: 'inactive', 'active';
* *deviceLabel* - the device label; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *deviceType* - the device type; * `recipientEmail` - email of the recipient;
* *eventType* - one of: 'inactive', 'active'; * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
Let's assume the notification about inactive thermometer device 'Sensor T1'. Let's assume the notification about inactive thermometer device 'Sensor T1'.
The following template: The following template:
Template message: ``
```text ```text
Device '${deviceName}' inactive Device '${deviceName}' inactive
{:copy-code} {:copy-code}
@ -42,11 +42,10 @@ will be transformed to:
```text ```text
Device 'Sensor T1' inactive Device 'Sensor T1' inactive
{:copy-code}
``` ```
<br/>
<br>
The following template: The following template:
```text ```text
@ -58,7 +57,7 @@ will be transformed to:
```text ```text
Thermometer 'Sensor T1' became inactive Thermometer 'Sensor T1' became inactive
{:copy-code}
``` ```
<br> <br>
<br> <br>

36
ui-ngx/src/assets/help/en_US/notification/entities_limit.md

@ -3,33 +3,36 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `entityType` - one of: 'Device', 'Asset', 'User', etc.;
* *recipientFirstName* - first name of the recipient; * `currentCount` - the current count of entities;
* *recipientLastName* - last name of the recipient; * `limit` - the limit on number of entities;
* *entityType* - one of: 'Device', 'Asset', 'User', etc.; * `percents` - the percent from the notification rule configuration;
* *currentCount* - the current count of entities; * `tenantId` - id of the tenant;
* *limit* - the limit on number of entities; * `tenantName` - name of the tenant;
* *percents* - the percent from the notification rule configuration; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *tenantId* - id of the tenant; * `recipientEmail` - email of the recipient;
* *tenantName* - name of the tenant; * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
Let's assume the tenant created 400 devices with the max allowed number is 500 and rule threshold 0.8 (80%). The following template: Let's assume the tenant created 400 devices with the max allowed number is 500 and rule threshold 0.8 (80%).
The following template:
```text ```text
${entityType:capitalize}s usage: ${currentCount}/${limit} (${percents}%) ${entityType:capitalize}s usage: ${currentCount}/${limit} (${percents}%)
@ -40,7 +43,6 @@ will be transformed to:
```text ```text
Devices usage: 400/500 (80%) Devices usage: 400/500 (80%)
{:copy-code}
``` ```
<br> <br>

48
ui-ngx/src/assets/help/en_US/notification/entity_action.md

@ -3,35 +3,38 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `entityType` - the entity type, e.g. 'Device';
* *recipientFirstName* - first name of the recipient; * `entityId` - the entity id as uuid string;
* *recipientLastName* - last name of the recipient; * `entityName` - the name of the entity;
* *entityType* - the entity type, e.g. 'Device'; * `actionType` - one of: 'added', 'updated', 'deleted';
* *entityId* - the entity id as uuid string; * `userId` - id of the user who made the action;
* *entityName* - the name of the entity; * `userTitle` - title of the user who made the action;
* *actionType* - one of: 'added', 'updated', 'deleted'; * `userEmail` - email of the user who made the action;
* *userId* - id of the user who made the action; * `userFirstName` - first name of the user who made the action;
* *userEmail* - email of the user who made the action; * `userLastName` - last name of the user who made the action;
* *userFirstName* - first name of the user who made the action; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *userLastName* - last name of the user who made the action; * `recipientEmail` - email of the recipient;
* `recipientFirstName` - first name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`. * `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
##### Examples ##### Examples
Let's assume the notification about device 'T1' was added by user 'john.doe@gmail.com'. Let's assume the notification about device 'T1' was added by user 'john.doe@gmail.com'.
The following template: The following template:
```text ```text
@ -43,22 +46,21 @@ will be transformed to:
```text ```text
Device was added! Device was added!
{:copy-code}
``` ```
<br> <br/>
The following template: The following template:
```text ```text
${entityType} '${entityName}' was ${actionType} by user '${originatorUserName}'! ${entityType} '${entityName}' was ${actionType} by user ${userEmail}
{:copy-code} {:copy-code}
``` ```
will be transformed to: will be transformed to:
```text ```text
Device 'T1' was added by user 'john.doe@gmail.com'! Device 'T1' was added by user john.doe@gmail.com
{:copy-code}
``` ```
<br> <br>

19
ui-ngx/src/assets/help/en_US/notification/general.md

@ -3,21 +3,23 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *recipientFirstName* - first name of the recipient; * `recipientEmail` - email of the recipient;
* *recipientLastName* - last name of the recipient; * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`. Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
@ -34,7 +36,6 @@ will be transformed to:
```text ```text
Hi, John! Hi, John!
{:copy-code}
``` ```
<br> <br>

31
ui-ngx/src/assets/help/en_US/notification/new_platform_version.md

@ -3,26 +3,28 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `latestVersion` - the latest platform version available;
* *recipientFirstName* - first name of the recipient; * `latestVersionReleaseNotesUrl` - release notes link for latest version;
* *recipientLastName* - last name of the recipient; * `upgradeInstructionsUrl` - upgrade instructions link for latest version;
* *latestVersion* - the latest platform version available; * `currentVersion` - the current platform version
* *latestVersionReleaseNotesUrl* - release notes link for latest version; * `currentVersionReleaseNotesUrl` - release notes link for current version;
* *upgradeInstructionsUrl* - upgrade instructions link for latest version; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *currentVersion* - the current platform version * `recipientEmail` - email of the recipient;
* *currentVersionReleaseNotesUrl* - release notes link for current version; * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
@ -39,7 +41,6 @@ will be transformed to:
```text ```text
New version 3.5.0 is available. Current version is 3.4.4 New version 3.5.0 is available. Current version is 3.4.4
{:copy-code}
``` ```
<br> <br>

54
ui-ngx/src/assets/help/en_US/notification/rule_engine.md

@ -1,54 +0,0 @@
#### Rule engine notification templatization
<div class="divider"></div>
<br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type.
See the available types and parameters below:
Available template parameters:
* values from the incoming message metadata;
* values from the incoming message data;
* *originatorType* - type of the originator, e.g. 'Device';
* *originatorId* - id of the originator
* *msgType* - type of the message
* *recipientEmail* - email of the recipient;
* *recipientFirstName* - first name of the recipient;
* *recipientLastName* - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div>
##### Examples
Let's assume the incoming message to Rule node has the following data:
```json
{
"building_1": {
"temperature": 24
}
}
```
The following template:
```text
Building 1: temperature is ${building_1.temperature}
{:copy-code}
```
will be transformed to:
```text
Building 1: temperature is 24
```
<br>
<br>

37
ui-ngx/src/assets/help/en_US/notification/rule_engine_lifecycle_event.md

@ -3,29 +3,31 @@
<div class="divider"></div> <div class="divider"></div>
<br/> <br/>
Notification subject and message fields support templatization. The list of available templatization parameters depends on the template type. Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below: See the available types and parameters below:
Available template parameters: Available template parameters:
* *recipientEmail* - email of the recipient; * `componentType` - one of: 'Rule chain', 'Rule node';
* *recipientFirstName* - first name of the recipient; * `componentId` - the component id as uuid string;
* *recipientLastName* - last name of the recipient; * `componentName` - the rule chain or rule node name;
* *componentType* - one of: 'Rule chain', 'Rule node'; * `ruleChainId` - the rule chain id as uuid string;
* *componentId* - the component id as uuid string; * `ruleChainName` - the rule chain name;
* *componentName* - the rule chain or rule node name; * `eventType` - one of: 'started', 'updated', 'stopped';
* *ruleChainId* - the rule chain id as uuid string; * `action` - one of: 'start', 'update', 'stop';
* *ruleChainName* - the rule chain name; * `error` - the error text;
* *eventType* - one of: 'started', 'updated', 'stopped'; * `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* *action* - one of: 'start', 'update', 'stop'; * `recipientEmail` - email of the recipient;
* *error* - the error text; * `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes: You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}` * `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}` * `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}` * `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div> <div class="divider"></div>
@ -42,7 +44,6 @@ will be transformed to:
```text ```text
Rule node 'Export to Kafka' - start failure:<br/>Connection refused! Rule node 'Export to Kafka' - start failure:<br/>Connection refused!
{:copy-code}
``` ```
<br> <br>

57
ui-ngx/src/assets/help/en_US/notification/rule_node.md

@ -0,0 +1,57 @@
#### Rule engine notification templatization
<div class="divider"></div>
<br/>
Notification subject and message fields support templatization.
The list of available templatization parameters depends on the template type.
See the available types and parameters below:
Available template parameters:
* values from the incoming message metadata;
* values from the incoming message data;
* `originatorType` - type of the originator, e.g. 'Device';
* `originatorId` - id of the originator
* `msgType` - type of the message
* `recipientTitle` - title of the recipient (first and last name if specified, email otherwise)
* `recipientEmail` - email of the recipient;
* `recipientFirstName` - first name of the recipient;
* `recipientLastName` - last name of the recipient;
Parameter names must be wrapped using `${...}`. For example: `${recipientFirstName}`.
You may also modify the value of the parameter with one of the suffixes:
* `upperCase`, for example - `${recipientFirstName:upperCase}`
* `lowerCase`, for example - `${recipientFirstName:lowerCase}`
* `capitalize`, for example - `${recipientFirstName:capitalize}`
<div class="divider"></div>
##### Examples
Let's assume the incoming message to Rule node has the following data:
```json
{
"building_1": {
"temperature": 24
}
}
```
The following template:
```text
Building 1: temperature is ${building_1.temperature}
{:copy-code}
```
will be transformed to:
```text
Building 1: temperature is 24
```
<br>
<br>
Loading…
Cancel
Save