コード例 #1
0
ファイル: TagService.cs プロジェクト: bakerboy448/Prowlarr
        public TagDetails Details(int tagId)
        {
            var tag            = GetTag(tagId);
            var notifications  = _notificationFactory.AllForTag(tagId);
            var indexers       = _indexerFactory.AllForTag(tagId);
            var indexerProxies = _indexerProxyFactory.AllForTag(tagId);

            return(new TagDetails
            {
                Id = tagId,
                Label = tag.Label,
                NotificationIds = notifications.Select(c => c.Id).ToList(),
                IndexerIds = indexers.Select(c => c.Id).ToList(),
                IndexerProxyIds = indexerProxies.Select(c => c.Id).ToList()
            });
        }
コード例 #2
0
        public TagDetails Details(int tagId)
        {
            var tag           = GetTag(tagId);
            var delayProfiles = _delayProfileService.AllForTag(tagId);
            var importLists   = _importListFactory.AllForTag(tagId);
            var notifications = _notificationFactory.AllForTag(tagId);
            var restrictions  = _restrictionService.AllForTag(tagId);
            var movies        = _movieService.AllMovieTags().Where(x => x.Value.Contains(tagId)).Select(x => x.Key).ToList();
            var indexers      = _indexerService.AllForTag(tagId);

            return(new TagDetails
            {
                Id = tagId,
                Label = tag.Label,
                DelayProfileIds = delayProfiles.Select(c => c.Id).ToList(),
                ImportListIds = importLists.Select(c => c.Id).ToList(),
                NotificationIds = notifications.Select(c => c.Id).ToList(),
                RestrictionIds = restrictions.Select(c => c.Id).ToList(),
                MovieIds = movies,
                IndexerIds = indexers.Select(c => c.Id).ToList()
            });
        }
コード例 #3
0
ファイル: TagService.cs プロジェクト: luisriverag/Sonarr
        public TagDetails Details(int tagId)
        {
            var tag           = GetTag(tagId);
            var delayProfiles = _delayProfileService.AllForTag(tagId);
            var importLists   = _importListFactory.AllForTag(tagId);
            var notifications = _notificationFactory.AllForTag(tagId);
            var restrictions  = _releaseProfileService.AllForTag(tagId);
            var series        = _seriesService.AllForTag(tagId);
            var indexers      = _indexerService.AllForTag(tagId);

            return(new TagDetails
            {
                Id = tagId,
                Label = tag.Label,
                DelayProfileIds = delayProfiles.Select(c => c.Id).ToList(),
                ImportListIds = importLists.Select(c => c.Id).ToList(),
                NotificationIds = notifications.Select(c => c.Id).ToList(),
                RestrictionIds = restrictions.Select(c => c.Id).ToList(),
                SeriesIds = series.Select(c => c.Id).ToList(),
                IndexerIds = indexers.Select(c => c.Id).ToList()
            });
        }