mirror of
https://github.com/Ombi-app/Ombi.git
synced 2025-08-19 12:59:39 -07:00
Changed the title to a contains but the artist still must match,
This commit is contained in:
parent
837572a8cd
commit
f9cf728381
3 changed files with 17 additions and 5 deletions
|
@ -108,7 +108,7 @@ namespace PlexRequests.Services.Tests
|
||||||
var requestMock = new Mock<IRequestService>();
|
var requestMock = new Mock<IRequestService>();
|
||||||
var plexMock = new Mock<IPlexApi>();
|
var plexMock = new Mock<IPlexApi>();
|
||||||
|
|
||||||
var searchResult = new PlexSearch { Directory = new List<Directory1> { new Directory1 { Title = "title2", Year = "1992", ParentTitle = "dIzZy" } } };
|
var searchResult = new PlexSearch { Directory = new List<Directory1> { new Directory1 { Title = "titale2", Year = "1992", ParentTitle = "dIzZy" } } };
|
||||||
|
|
||||||
settingsMock.Setup(x => x.GetSettings()).Returns(new PlexSettings { Ip = "abc" });
|
settingsMock.Setup(x => x.GetSettings()).Returns(new PlexSettings { Ip = "abc" });
|
||||||
authMock.Setup(x => x.GetSettings()).Returns(new AuthenticationSettings { PlexAuthToken = "abc" });
|
authMock.Setup(x => x.GetSettings()).Returns(new AuthenticationSettings { PlexAuthToken = "abc" });
|
||||||
|
|
|
@ -235,7 +235,7 @@ namespace PlexRequests.Services
|
||||||
{
|
{
|
||||||
foreach (var r in results.Directory)
|
foreach (var r in results.Directory)
|
||||||
{
|
{
|
||||||
var titleMatch = r.Title.Equals(title, StringComparison.CurrentCultureIgnoreCase);
|
var titleMatch = r.Title.Contains(title);
|
||||||
var artistMatch = r.ParentTitle.Equals(artist, StringComparison.CurrentCultureIgnoreCase);
|
var artistMatch = r.ParentTitle.Equals(artist, StringComparison.CurrentCultureIgnoreCase);
|
||||||
if (titleMatch && artistMatch)
|
if (titleMatch && artistMatch)
|
||||||
{
|
{
|
||||||
|
|
|
@ -46,6 +46,10 @@ $('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
|
||||||
activeState = $ml.mixItUp('getState');
|
activeState = $ml.mixItUp('getState');
|
||||||
$ml.mixItUp('destroy');
|
$ml.mixItUp('destroy');
|
||||||
}
|
}
|
||||||
|
if ($musicL.mixItUp('isLoaded')) {
|
||||||
|
activeState = $musicL.mixItUp('getState');
|
||||||
|
$musicL.mixItUp('destroy');
|
||||||
|
}
|
||||||
if ($tvl.mixItUp('isLoaded')) $tvl.mixItUp('destroy');
|
if ($tvl.mixItUp('isLoaded')) $tvl.mixItUp('destroy');
|
||||||
$tvl.mixItUp(mixItUpConfig(activeState)); // init or reinit
|
$tvl.mixItUp(mixItUpConfig(activeState)); // init or reinit
|
||||||
}
|
}
|
||||||
|
@ -55,15 +59,23 @@ $('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
|
||||||
activeState = $tvl.mixItUp('getState');
|
activeState = $tvl.mixItUp('getState');
|
||||||
$tvl.mixItUp('destroy');
|
$tvl.mixItUp('destroy');
|
||||||
}
|
}
|
||||||
|
if ($musicL.mixItUp('isLoaded')) {
|
||||||
|
activeState = $musicL.mixItUp('getState');
|
||||||
|
$musicL.mixItUp('destroy');
|
||||||
|
}
|
||||||
if ($ml.mixItUp('isLoaded')) $ml.mixItUp('destroy');
|
if ($ml.mixItUp('isLoaded')) $ml.mixItUp('destroy');
|
||||||
$ml.mixItUp(mixItUpConfig(activeState)); // init or reinit
|
$ml.mixItUp(mixItUpConfig(activeState)); // init or reinit
|
||||||
}
|
}
|
||||||
|
|
||||||
if (target === "#MusicTab") {
|
if (target === "#MusicTab") {
|
||||||
$('#approveMusic').show();
|
$('#approveMusic').show();
|
||||||
if ($musicL.mixItUp('isLoaded')) {
|
if ($tvl.mixItUp('isLoaded')) {
|
||||||
activeState = $musicL.mixItUp('getState');
|
activeState = $tvl.mixItUp('getState');
|
||||||
$musicL.mixItUp('destroy');
|
$tvl.mixItUp('destroy');
|
||||||
|
}
|
||||||
|
if ($ml.mixItUp('isLoaded')) {
|
||||||
|
activeState = $ml.mixItUp('getState');
|
||||||
|
$ml.mixItUp('destroy');
|
||||||
}
|
}
|
||||||
if ($musicL.mixItUp('isLoaded')) $ml.mixItUp('destroy');
|
if ($musicL.mixItUp('isLoaded')) $ml.mixItUp('destroy');
|
||||||
$musicL.mixItUp(mixItUpConfig(activeState)); // init or reinit
|
$musicL.mixItUp(mixItUpConfig(activeState)); // init or reinit
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue