mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-19 21:03:17 -07:00
Fixed #17000
This commit is contained in:
parent
588f314e9c
commit
874d90d894
4 changed files with 24 additions and 4 deletions
|
@ -19,7 +19,7 @@ namespace Ombi.Api.Github
|
|||
|
||||
public async Task<List<CakeThemes>> GetCakeThemes()
|
||||
{
|
||||
var request = new Request("repos/tidusjar/layer.Cake/contents/ombi/themes", BaseUrl, HttpMethod.Get);
|
||||
var request = new Request("repos/leram84/layer.Cake/contents/ombi/themes", BaseUrl, HttpMethod.Get);
|
||||
request.AddHeader("Accept", "application/vnd.github.v3+json");
|
||||
request.AddHeader("User-Agent", "Ombi");
|
||||
return await _api.Request<List<CakeThemes>>(request);
|
||||
|
|
|
@ -19,7 +19,19 @@ namespace Ombi.Core.Rule.Rules.Search
|
|||
|
||||
public async Task<RuleResult> Execute(SearchViewModel obj)
|
||||
{
|
||||
var item = await EmbyContentRepository.Get(obj.ImdbId);
|
||||
EmbyContent item = null;
|
||||
if (obj.Type == RequestType.Movie)
|
||||
{
|
||||
item = await EmbyContentRepository.Get(obj.ImdbId);
|
||||
if (item == null)
|
||||
{
|
||||
item = await EmbyContentRepository.Get(obj.TheMovieDbId);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
item = await EmbyContentRepository.Get(obj.TheTvDbId);
|
||||
}
|
||||
if (item != null)
|
||||
{
|
||||
obj.Available = true;
|
||||
|
|
|
@ -35,6 +35,7 @@ namespace Ombi.Store.Entities
|
|||
public class EmbyContent : Entity
|
||||
{
|
||||
public string Title { get; set; }
|
||||
|
||||
public string ProviderId { get; set; }
|
||||
public string EmbyId { get; set; }
|
||||
public EmbyMediaType Type { get; set; }
|
||||
|
|
|
@ -33,6 +33,7 @@ export class CustomizationComponent implements OnInit {
|
|||
|
||||
if(x.hasPresetTheme) {
|
||||
this.themes.unshift({displayName: x.presetThemeDisplayName, fullName: x.presetThemeName, url: "", version: x.presetThemeVersion});
|
||||
this.themes.unshift({displayName: "None", fullName: "None", url: "", version: ""});
|
||||
} else {
|
||||
this.themes.unshift({displayName: "Please Select", fullName: "-1", url: "-1", version: ""});
|
||||
}
|
||||
|
@ -55,9 +56,15 @@ export class CustomizationComponent implements OnInit {
|
|||
const selectedThemeFullName = <string>event.target.value;
|
||||
const selectedTheme = this.themes.filter((val) => {
|
||||
return val.fullName === selectedThemeFullName;
|
||||
});
|
||||
})[0];
|
||||
|
||||
if(selectedTheme[0].fullName === this.settings.presetThemeName) {
|
||||
if(selectedTheme.fullName === this.settings.presetThemeName) {
|
||||
return;
|
||||
}
|
||||
|
||||
if(selectedTheme.fullName === "None" || selectedTheme.fullName === "-1") {
|
||||
this.settings.presetThemeName = "";
|
||||
this.settings.presetThemeContent = "";
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue