diff --git a/server/notification-providers/slack.js b/server/notification-providers/slack.js index 12207bd4f..41c2bd02c 100644 --- a/server/notification-providers/slack.js +++ b/server/notification-providers/slack.js @@ -27,6 +27,11 @@ class Slack extends NotificationProvider { async send(notification, msg, monitorJSON = null, heartbeatJSON = null) { let okMsg = "Sent Successfully."; + + if (notification.slackchannelnotify) { + msg += " "; + } + try { if (heartbeatJSON == null) { let data = { @@ -53,7 +58,7 @@ class Slack extends NotificationProvider { "type": "header", "text": { "type": "plain_text", - "text": "Uptime Kuma Alert", + "text": textMsg, }, }, { diff --git a/src/components/notifications/Slack.vue b/src/components/notifications/Slack.vue index 6d220caad..dead709ce 100644 --- a/src/components/notifications/Slack.vue +++ b/src/components/notifications/Slack.vue @@ -24,5 +24,13 @@ https://www.webfx.com/tools/emoji-cheat-sheet/ + +
+ + +
+
+ {{ $t("aboutNotifyChannel") }} +
diff --git a/src/lang/en.json b/src/lang/en.json index c4f1fa0dc..bc4f9ce33 100644 --- a/src/lang/en.json +++ b/src/lang/en.json @@ -640,6 +640,8 @@ "matrixDesc1": "You can find the internal room ID by looking in the advanced section of the room settings in your Matrix client. It should look like !QMdRCpUIfLwsfjxye6:home.server.", "matrixDesc2": "It is highly recommended you create a new user and do not use your own Matrix user's access token as it will allow full access to your account and all the rooms you joined. Instead, create a new user and only invite it to the room that you want to receive the notification in. You can get the access token by running {0}", "Channel Name": "Channel Name", + "Notify Channel": "Notify Channel", + "aboutNotifyChannel": "Notify channel will trigger a desktop or mobile notification for all members of the channel, whether their availability is set to active or away.", "Uptime Kuma URL": "Uptime Kuma URL", "Icon Emoji": "Icon Emoji", "signalImportant": "IMPORTANT: You cannot mix groups and numbers in recipients!",