mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
image link from remote web client fix
This commit is contained in:
parent
31f53d0855
commit
5a6b097ed9
1 changed files with 4 additions and 4 deletions
|
@ -66,14 +66,14 @@ define(['dialogHelper', 'inputManager', 'connectionManager', 'layoutManager', 'f
|
||||||
* @param {object} item - Item used to generate the image URL.
|
* @param {object} item - Item used to generate the image URL.
|
||||||
* @returns {string} URL of the item's image.
|
* @returns {string} URL of the item's image.
|
||||||
*/
|
*/
|
||||||
function getImgUrl(item) {
|
function getImgUrl(item, user) {
|
||||||
var apiClient = connectionManager.getApiClient(item.ServerId);
|
var apiClient = connectionManager.getApiClient(item.ServerId);
|
||||||
var imageOptions = {};
|
var imageOptions = {};
|
||||||
|
|
||||||
if (item.BackdropImageTags && item.BackdropImageTags.length) {
|
if (item.BackdropImageTags && item.BackdropImageTags.length) {
|
||||||
return getBackdropImageUrl(item, imageOptions, apiClient);
|
return getBackdropImageUrl(item, imageOptions, apiClient);
|
||||||
} else {
|
} else {
|
||||||
if (item.MediaType === 'Photo') {
|
if (item.MediaType === 'Photo' && user.Policy.EnableContentDownloading) {
|
||||||
return apiClient.getItemDownloadUrl(item.Id);
|
return apiClient.getItemDownloadUrl(item.Id);
|
||||||
}
|
}
|
||||||
imageOptions.type = "Primary";
|
imageOptions.type = "Primary";
|
||||||
|
@ -312,7 +312,7 @@ define(['dialogHelper', 'inputManager', 'connectionManager', 'layoutManager', 'f
|
||||||
*/
|
*/
|
||||||
function getSwiperSlideHtmlFromItem(item) {
|
function getSwiperSlideHtmlFromItem(item) {
|
||||||
return getSwiperSlideHtmlFromSlide({
|
return getSwiperSlideHtmlFromSlide({
|
||||||
originalImage: getImgUrl(item),
|
originalImage: getImgUrl(item, currentOptions.user),
|
||||||
//title: item.Name,
|
//title: item.Name,
|
||||||
//description: item.Overview
|
//description: item.Overview
|
||||||
Id: item.Id,
|
Id: item.Id,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue