mirror of
https://github.com/Radarr/Radarr
synced 2025-02-21 13:57:02 +00:00
Fixed: Hopefully fixed bulk import not showing files.
This commit is contained in:
parent
e01900628f
commit
6c45c7db1b
1 changed files with 9 additions and 2 deletions
|
@ -14,6 +14,7 @@
|
|||
using NzbDrone.Core.RootFolders;
|
||||
using NzbDrone.Common.Cache;
|
||||
using NzbDrone.Core.Movies;
|
||||
using NzbDrone.Core.Profiles;
|
||||
|
||||
namespace NzbDrone.Api.Movies
|
||||
{
|
||||
|
@ -34,12 +35,13 @@ public class MovieBulkImportModule : NzbDroneRestModule<MovieResource>
|
|||
private readonly IDiskScanService _diskScanService;
|
||||
private readonly ICached<Core.Movies.Movie> _mappedMovies;
|
||||
private readonly IParsingService _parsingService;
|
||||
private readonly IProfileService _profileService;
|
||||
private readonly IMovieService _movieService;
|
||||
|
||||
public MovieBulkImportModule(ISearchForNewMovie searchProxy, IRootFolderService rootFolderService,
|
||||
IMakeImportDecision importDecisionMaker,
|
||||
IDiskScanService diskScanService, ICacheManager cacheManager,
|
||||
IParsingService parsingService, IMovieService movieService)
|
||||
IParsingService parsingService, IProfileService profileService, IMovieService movieService)
|
||||
: base("/movies/bulkimport")
|
||||
{
|
||||
_searchProxy = searchProxy;
|
||||
|
@ -48,6 +50,7 @@ public MovieBulkImportModule(ISearchForNewMovie searchProxy, IRootFolderService
|
|||
_diskScanService = diskScanService;
|
||||
_mappedMovies = cacheManager.GetCache<Core.Movies.Movie>(GetType(), "mappedMoviesCache");
|
||||
_movieService = movieService;
|
||||
_profileService = profileService;
|
||||
_parsingService = parsingService;
|
||||
Get["/"] = x => Search();
|
||||
}
|
||||
|
@ -60,6 +63,8 @@ private Response Search()
|
|||
//Todo error handling
|
||||
}
|
||||
|
||||
Profile tempProfile = _profileService.All().First();
|
||||
|
||||
RootFolder rootFolder = _rootFolderService.Get(Request.Query.Id);
|
||||
|
||||
int page = Request.Query.page;
|
||||
|
@ -100,6 +105,7 @@ private Response Search()
|
|||
{
|
||||
Title = f.Name.Replace(".", " ").Replace("-", " "),
|
||||
Path = f.Path,
|
||||
Profile = tempProfile
|
||||
};
|
||||
}
|
||||
else
|
||||
|
@ -111,7 +117,8 @@ private Response Search()
|
|||
Title = parsedTitle.MovieTitle,
|
||||
Year = parsedTitle.Year,
|
||||
ImdbId = parsedTitle.ImdbId,
|
||||
Path = f.Path
|
||||
Path = f.Path,
|
||||
Profile = tempProfile
|
||||
};
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue