mirror of
https://github.com/Prowlarr/Prowlarr.git
synced 2025-09-27 12:33:00 +02:00
SignalR will now update quality in UI as well (when applicable)
This commit is contained in:
@@ -4,6 +4,7 @@ using System.Linq;
|
||||
using System.Text;
|
||||
using NLog;
|
||||
using NzbDrone.Core.Model;
|
||||
using NzbDrone.Core.Repository.Quality;
|
||||
using SignalR;
|
||||
using SignalR.Hosting.AspNet;
|
||||
using SignalR.Hubs;
|
||||
@@ -15,11 +16,25 @@ namespace NzbDrone.Core.Providers
|
||||
{
|
||||
private static readonly Logger logger = LogManager.GetCurrentClassLogger();
|
||||
|
||||
public virtual void UpdateEpisodeStatus(int episodeId, EpisodeStatusType episodeStatus)
|
||||
public virtual void UpdateEpisodeStatus(int episodeId, EpisodeStatusType episodeStatus, Quality quality)
|
||||
{
|
||||
logger.Trace("Sending Status update to client. EpisodeId: {0}, Status: {1}", episodeId, episodeStatus);
|
||||
try
|
||||
{
|
||||
logger.Trace("Sending Status update to client. EpisodeId: {0}, Status: {1}", episodeId, episodeStatus);
|
||||
|
||||
GetClients().updatedStatus(episodeId, episodeStatus.ToString());
|
||||
GetClients().updatedStatus(new
|
||||
{
|
||||
EpisodeId = episodeId,
|
||||
EpisodeStatus = episodeStatus.ToString(),
|
||||
Quality = (quality == null ? String.Empty : quality.QualityType.ToString())
|
||||
});
|
||||
var test = 0;
|
||||
}
|
||||
catch (Exception ex)
|
||||
{
|
||||
logger.Trace("Error");
|
||||
throw;
|
||||
}
|
||||
}
|
||||
|
||||
private dynamic GetClients()
|
||||
|
Reference in New Issue
Block a user