Also added new notification variables and a new notification when someone adds a comment on an issue.
This commit is contained in:
tidusjar 2018-02-07 23:30:23 +00:00
commit 480a107fa6
15 changed files with 322 additions and 42 deletions

View file

@ -205,6 +205,17 @@ namespace Ombi.Store.Context
Enabled = true,
};
break;
case NotificationType.IssueComment:
notificationToAdd = new NotificationTemplates
{
NotificationType = notificationType,
Message = "Hello, There is a new comment on your issue {IssueSubject}, The comment is: {NewIssueComment}",
Subject = "{ApplicationName}: New comment on issue {IssueSubject}!",
Agent = agent,
Enabled = true,
};
break;
case NotificationType.AdminNote:
continue;
default:

View file

@ -66,7 +66,11 @@ namespace Ombi.Store.Repository
var item = await Db.PlexServerContent.FirstOrDefaultAsync(x => x.ImdbId == providerId);
if (item == null)
{
item = await Db.PlexServerContent.FirstOrDefaultAsync(x => x.TheMovieDbId == providerId) ?? await Db.PlexServerContent.FirstOrDefaultAsync(x => x.TvDbId == providerId);
item = await Db.PlexServerContent.FirstOrDefaultAsync(x => x.TheMovieDbId == providerId);
if (item == null)
{
item = await Db.PlexServerContent.FirstOrDefaultAsync(x => x.TvDbId == providerId);
}
}
return item;
}