pull/1654/head
Jamie 7 years ago
parent 588f314e9c
commit 874d90d894

@ -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,12 +56,18 @@ 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;
}
this.settings.presetThemeName = selectedThemeFullName;
this.settingsService.getThemeContent(selectedTheme[0].url).subscribe(x => {
this.settings.presetThemeContent = x;

Loading…
Cancel
Save