|
|
@ -103,11 +103,11 @@ namespace NzbDrone.Core.ImportLists.Lidarr
|
|
|
|
return new
|
|
|
|
return new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
options = devices.OrderBy(d => d.Name, StringComparer.InvariantCultureIgnoreCase)
|
|
|
|
options = devices.OrderBy(d => d.Name, StringComparer.InvariantCultureIgnoreCase)
|
|
|
|
.Select(d => new
|
|
|
|
.Select(d => new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Value = d.Id,
|
|
|
|
Value = d.Id,
|
|
|
|
Name = d.Name
|
|
|
|
Name = d.Name
|
|
|
|
})
|
|
|
|
})
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
@ -118,28 +118,26 @@ namespace NzbDrone.Core.ImportLists.Lidarr
|
|
|
|
return new
|
|
|
|
return new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
options = devices.OrderBy(d => d.Label, StringComparer.InvariantCultureIgnoreCase)
|
|
|
|
options = devices.OrderBy(d => d.Label, StringComparer.InvariantCultureIgnoreCase)
|
|
|
|
.Select(d => new
|
|
|
|
.Select(d => new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Value = d.Id,
|
|
|
|
Value = d.Id,
|
|
|
|
Name = d.Label
|
|
|
|
Name = d.Label
|
|
|
|
})
|
|
|
|
})
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
if (action == "getRootFolders")
|
|
|
|
if (action == "getRootFolders")
|
|
|
|
{
|
|
|
|
{
|
|
|
|
Settings.Validate().Filter("ApiKey").ThrowOnError();
|
|
|
|
var remoteRootFolders = _lidarrV1Proxy.GetRootFolders(Settings);
|
|
|
|
|
|
|
|
|
|
|
|
var remoteRootfolders = _lidarrV1Proxy.GetRootFolders(Settings);
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
return new
|
|
|
|
return new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
options = remoteRootfolders.OrderBy(d => d.Path, StringComparer.InvariantCultureIgnoreCase)
|
|
|
|
options = remoteRootFolders.OrderBy(d => d.Path, StringComparer.InvariantCultureIgnoreCase)
|
|
|
|
.Select(d => new
|
|
|
|
.Select(d => new
|
|
|
|
{
|
|
|
|
{
|
|
|
|
value = d.Path,
|
|
|
|
value = d.Path,
|
|
|
|
name = d.Path
|
|
|
|
name = d.Path
|
|
|
|
})
|
|
|
|
})
|
|
|
|
};
|
|
|
|
};
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|