Fixed dynamic jobs with single property

This commit is contained in:
Mark McDowall 2012-10-19 21:36:47 -07:00
parent f9370a8aec
commit 887456b337
5 changed files with 9 additions and 9 deletions

View File

@ -199,7 +199,7 @@ namespace NzbDrone.Core.Providers
}
else
{
notification.CurrentMessage = String.Format("Sorry, couldn't find you {0} in any of indexers.", episode);
notification.CurrentMessage = String.Format("Sorry, couldn't find {0} in any of indexers.", episode);
}
return false;

View File

@ -60,9 +60,9 @@ namespace NzbDrone.Web.Controllers
public JsonResult ForceRefresh(int seriesId)
{
_jobProvider.QueueJob(typeof(UpdateInfoJob), seriesId);
_jobProvider.QueueJob(typeof(DiskScanJob), seriesId);
_jobProvider.QueueJob(typeof(RefreshEpisodeMetadata), seriesId);
_jobProvider.QueueJob(typeof(UpdateInfoJob), new { SeriesId = seriesId });
_jobProvider.QueueJob(typeof(DiskScanJob), new { SeriesId = seriesId });
_jobProvider.QueueJob(typeof(RefreshEpisodeMetadata), new { SeriesId = seriesId });
return JsonNotificationResult.Queued("Episode update/Disk scan");
}

View File

@ -20,7 +20,7 @@ namespace NzbDrone.Web.Controllers
public JsonResult Search(int episodeId)
{
_jobProvider.QueueJob(typeof(EpisodeSearchJob), episodeId);
_jobProvider.QueueJob(typeof(EpisodeSearchJob), new { EpisodeId = episodeId });
return JsonNotificationResult.Queued("Episode search");
}
@ -33,7 +33,7 @@ namespace NzbDrone.Web.Controllers
public JsonResult BacklogSeries(int seriesId)
{
_jobProvider.QueueJob(typeof(SeriesSearchJob), seriesId);
_jobProvider.QueueJob(typeof(SeriesSearchJob), new { SeriesId = seriesId });
return JsonNotificationResult.Queued("Series Backlog");
}
@ -47,7 +47,7 @@ namespace NzbDrone.Web.Controllers
public JsonResult RenameSeries(int seriesId)
{
_jobProvider.QueueJob(typeof(RenameSeriesJob), seriesId);
_jobProvider.QueueJob(typeof(RenameSeriesJob), new { SeriesId = seriesId });
return JsonNotificationResult.Queued("Series rename");
}

View File

@ -90,7 +90,7 @@ namespace NzbDrone.Web.Controllers
_historyProvider.Delete(historyId);
//Queue a job to download the replacement episode
_jobProvider.QueueJob(typeof(EpisodeSearchJob), episodeId);
_jobProvider.QueueJob(typeof(EpisodeSearchJob), new { EpisodeId = episodeId });
return JsonNotificationResult.Queued("Episode search");
}

View File

@ -36,7 +36,7 @@ namespace NzbDrone.Web.Controllers
public ActionResult StartUpdate()
{
_jobProvider.QueueJob(typeof(AppUpdateJob), 0, 0);
_jobProvider.QueueJob(typeof(AppUpdateJob));
return JsonNotificationResult.Info("Update will begin shortly", "NzbDrone will restart automatically.");
}