mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-07-30 19:40:05 -07:00
Fixed #1914
Also added new notification variables and a new notification when someone adds a comment on an issue.
This commit is contained in:
parent
b223306ee8
commit
480a107fa6
15 changed files with 322 additions and 42 deletions
|
@ -69,6 +69,21 @@ namespace Ombi.Notifications.Agents
|
|||
await Send(notification, settings);
|
||||
}
|
||||
|
||||
protected override async Task IssueComment(NotificationOptions model, TelegramSettings settings)
|
||||
{
|
||||
var parsed = await LoadTemplate(NotificationAgent.Telegram, NotificationType.IssueComment, model);
|
||||
if (parsed.Disabled)
|
||||
{
|
||||
Logger.LogInformation($"Template {NotificationType.IssueComment} is disabled for {NotificationAgent.Telegram}");
|
||||
return;
|
||||
}
|
||||
var notification = new NotificationMessage
|
||||
{
|
||||
Message = parsed.Message,
|
||||
};
|
||||
await Send(notification, settings);
|
||||
}
|
||||
|
||||
protected override async Task IssueResolved(NotificationOptions model, TelegramSettings settings)
|
||||
{
|
||||
var parsed = await LoadTemplate(NotificationAgent.Telegram, NotificationType.IssueResolved, model);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue