update more from/similar

This commit is contained in:
Luke Pulverenti 2016-07-22 13:54:43 -04:00
parent cec6b66c27
commit 9272519d84

View file

@ -723,7 +723,7 @@
}
function renderMoreFromItems(page, item) {
var moreFromSection = page.querySelector('#moreFromSection');
if (!moreFromSection) {
@ -736,14 +736,14 @@
}
ApiClient.getItems(Dashboard.getCurrentUserId(), {
IncludeItemTypes: "MusicAlbum",
ArtistIds: item.AlbumArtists[0].Id,
Recursive: true,
ExcludeItemIds: item.Id
}).then(function(result) {
}).then(function (result) {
if (!result.Items.length) {
moreFromSection.classList.add('hide');
return;
@ -803,6 +803,10 @@
fields: "PrimaryImageAspectRatio,UserData,SyncInfo,CanDelete"
};
if (item.Type == 'MusicAlbum' && item.AlbumArtists && item.AlbumArtists.length) {
options.ExcludeArtistNames = item.AlbumArtists[0].Name;
}
if (enableScrollX()) {
options.limit = 12;
}