fix merge conflicts
This commit is contained in:
parent
155c519080
commit
708c000be5
|
@ -51,7 +51,7 @@ namespace MediaBrowser.Providers.Folders
|
|||
|
||||
if (!string.IsNullOrWhiteSpace(url))
|
||||
{
|
||||
list.AddRange(new List<RemoteImageInfo>{
|
||||
list.AddRange(new List<RemoteImageInfo>{
|
||||
new RemoteImageInfo
|
||||
{
|
||||
ProviderName = Name,
|
||||
|
@ -93,7 +93,7 @@ namespace MediaBrowser.Providers.Folders
|
|||
}
|
||||
if (string.Equals(viewType, CollectionType.TvShows, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
return urlPrefix + "tv.jpg";
|
||||
//return urlPrefix + "tv.jpg";
|
||||
}
|
||||
if (string.Equals(viewType, CollectionType.Channels, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
|
@ -105,7 +105,7 @@ namespace MediaBrowser.Providers.Folders
|
|||
}
|
||||
if (string.Equals(viewType, CollectionType.Movies, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
return urlPrefix + "movies.jpg";
|
||||
//return urlPrefix + "movies.jpg";
|
||||
}
|
||||
if (string.Equals(viewType, CollectionType.Playlists, StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
|
|
|
@ -560,12 +560,6 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
}
|
||||
item.ExternalId = channelInfo.Id;
|
||||
|
||||
if (!item.ParentId.Equals(parentFolderId))
|
||||
{
|
||||
isNew = true;
|
||||
}
|
||||
item.ParentId = parentFolderId;
|
||||
|
||||
item.ChannelType = channelInfo.ChannelType;
|
||||
item.ServiceName = serviceName;
|
||||
item.Number = channelInfo.Number;
|
||||
|
@ -628,12 +622,6 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
};
|
||||
}
|
||||
|
||||
if (!item.ParentId.Equals(channel.Id))
|
||||
{
|
||||
forceUpdate = true;
|
||||
}
|
||||
item.ParentId = channel.Id;
|
||||
|
||||
//item.ChannelType = channelType;
|
||||
if (!string.Equals(item.ServiceName, serviceName, StringComparison.Ordinal))
|
||||
{
|
||||
|
@ -786,12 +774,6 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
}
|
||||
recording.IsSeries = info.IsSeries;
|
||||
|
||||
if (!item.ParentId.Equals(parentFolderId))
|
||||
{
|
||||
dataChanged = true;
|
||||
}
|
||||
item.ParentId = parentFolderId;
|
||||
|
||||
if (!item.HasImage(ImageType.Primary))
|
||||
{
|
||||
if (!string.IsNullOrWhiteSpace(info.ImagePath))
|
||||
|
@ -869,7 +851,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
{
|
||||
var user = string.IsNullOrEmpty(query.UserId) ? null : _userManager.GetUserById(query.UserId);
|
||||
|
||||
var internalQuery = new InternalItemsQuery(user)
|
||||
var internalQuery = new InternalItemsQuery
|
||||
{
|
||||
IncludeItemTypes = new[] { typeof(LiveTvProgram).Name },
|
||||
MinEndDate = query.MinEndDate,
|
||||
|
@ -887,6 +869,16 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
SortOrder = query.SortOrder ?? SortOrder.Ascending
|
||||
};
|
||||
|
||||
if (user != null)
|
||||
{
|
||||
internalQuery.MaxParentalRating = user.Policy.MaxParentalRating;
|
||||
|
||||
if (user.Policy.BlockUnratedItems.Contains(UnratedItem.LiveTvProgram))
|
||||
{
|
||||
internalQuery.HasParentalRating = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (query.HasAired.HasValue)
|
||||
{
|
||||
if (query.HasAired.Value)
|
||||
|
@ -921,7 +913,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
{
|
||||
var user = _userManager.GetUserById(query.UserId);
|
||||
|
||||
var internalQuery = new InternalItemsQuery(user)
|
||||
var internalQuery = new InternalItemsQuery
|
||||
{
|
||||
IncludeItemTypes = new[] { typeof(LiveTvProgram).Name },
|
||||
IsAiring = query.IsAiring,
|
||||
|
@ -930,6 +922,16 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
IsKids = query.IsKids
|
||||
};
|
||||
|
||||
if (user != null)
|
||||
{
|
||||
internalQuery.MaxParentalRating = user.Policy.MaxParentalRating;
|
||||
|
||||
if (user.Policy.BlockUnratedItems.Contains(UnratedItem.LiveTvProgram))
|
||||
{
|
||||
internalQuery.HasParentalRating = true;
|
||||
}
|
||||
}
|
||||
|
||||
if (query.HasAired.HasValue)
|
||||
{
|
||||
if (query.HasAired.Value)
|
||||
|
@ -1397,7 +1399,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
|
||||
await RefreshRecordings(cancellationToken).ConfigureAwait(false);
|
||||
|
||||
var internalQuery = new InternalItemsQuery(user)
|
||||
var internalQuery = new InternalItemsQuery
|
||||
{
|
||||
IncludeItemTypes = new[] { typeof(LiveTvVideoRecording).Name, typeof(LiveTvAudioRecording).Name }
|
||||
};
|
||||
|
@ -1407,8 +1409,8 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
internalQuery.ChannelIds = new[] { query.ChannelId };
|
||||
}
|
||||
|
||||
var queryResult = _libraryManager.GetItems(internalQuery, new string[] { });
|
||||
IEnumerable<ILiveTvRecording> recordings = queryResult.Cast<ILiveTvRecording>();
|
||||
var queryResult = _libraryManager.GetItems(internalQuery);
|
||||
IEnumerable<ILiveTvRecording> recordings = queryResult.Items.Cast<ILiveTvRecording>();
|
||||
|
||||
if (!string.IsNullOrEmpty(query.Id))
|
||||
{
|
||||
|
@ -1810,7 +1812,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
|
||||
var now = DateTime.UtcNow;
|
||||
|
||||
var programs = _libraryManager.GetItems(new InternalItemsQuery(user)
|
||||
var programs = _libraryManager.GetItems(new InternalItemsQuery
|
||||
{
|
||||
IncludeItemTypes = new[] { typeof(LiveTvProgram).Name },
|
||||
ChannelIds = new[] { id },
|
||||
|
@ -1819,7 +1821,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
Limit = 1,
|
||||
SortBy = new[] { "StartDate" }
|
||||
|
||||
}, new string[] { }).Cast<LiveTvProgram>();
|
||||
}).Items.Cast<LiveTvProgram>();
|
||||
|
||||
var currentProgram = programs.FirstOrDefault();
|
||||
|
||||
|
@ -1834,7 +1836,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
|
||||
var now = DateTime.UtcNow;
|
||||
|
||||
var programs = _libraryManager.GetItems(new InternalItemsQuery(user)
|
||||
var programs = _libraryManager.GetItems(new InternalItemsQuery
|
||||
{
|
||||
IncludeItemTypes = new[] { typeof(LiveTvProgram).Name },
|
||||
ChannelIds = new[] { channel.Id.ToString("N") },
|
||||
|
@ -1843,7 +1845,7 @@ namespace MediaBrowser.Server.Implementations.LiveTv
|
|||
Limit = 1,
|
||||
SortBy = new[] { "StartDate" }
|
||||
|
||||
}, new string[] { }).Cast<LiveTvProgram>();
|
||||
}).Items.Cast<LiveTvProgram>();
|
||||
|
||||
var currentProgram = programs.FirstOrDefault();
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user