mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-14 02:26:55 -07:00
Added better support for Jellyfin, we will now auto detect if it's a jellyfin server after pressing the discover button
This commit is contained in:
parent
2cfad10a82
commit
e5ef111087
15 changed files with 96 additions and 24 deletions
|
@ -1,21 +1,21 @@
|
|||
using System;
|
||||
using System.Globalization;
|
||||
using System.Collections.Generic;
|
||||
using System.Text;
|
||||
|
||||
namespace Ombi.Helpers
|
||||
namespace Ombi.Helpers
|
||||
{
|
||||
public class EmbyHelper
|
||||
{
|
||||
public static string GetEmbyMediaUrl(string mediaId, string customerServerUrl = null)
|
||||
public static string GetEmbyMediaUrl(string mediaId, string customerServerUrl = null, bool isJellyfin = false)
|
||||
{
|
||||
string path = "item/item";
|
||||
if (isJellyfin)
|
||||
{
|
||||
path = "itemdetails";
|
||||
}
|
||||
if (customerServerUrl.HasValue())
|
||||
{
|
||||
return $"{customerServerUrl}#!/item/item.html?id={mediaId}";
|
||||
return $"{customerServerUrl}#!/{path}.html?id={mediaId}";
|
||||
}
|
||||
else
|
||||
{
|
||||
return $"https://app.emby.media/#!/item/item.html?id={mediaId}";
|
||||
return $"https://app.emby.media/#!/{path}.html?id={mediaId}";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue