mirror of
https://github.com/lidarr/lidarr.git
synced 2025-07-11 23:57:11 -07:00
AutoComplete is now using jQuery UI AutoComplete.
Removed jquery.liveQuery.
This commit is contained in:
parent
59d4ae6219
commit
d330c65165
14 changed files with 107 additions and 380 deletions
|
@ -29,26 +29,26 @@ namespace NzbDrone.Web.Controllers
|
|||
}
|
||||
|
||||
[HttpGet]
|
||||
public JsonResult GetDirectories(string q)
|
||||
public JsonResult GetDirectories(string term)
|
||||
{
|
||||
string[] dirs = null;
|
||||
try
|
||||
{
|
||||
//Windows (Including UNC)
|
||||
var windowsSep = q.LastIndexOf('\\');
|
||||
var windowsSep = term.LastIndexOf('\\');
|
||||
|
||||
if (windowsSep > -1)
|
||||
{
|
||||
dirs = _diskProvider.GetDirectories(q.Substring(0, windowsSep + 1));
|
||||
dirs = _diskProvider.GetDirectories(term.Substring(0, windowsSep + 1));
|
||||
|
||||
}
|
||||
|
||||
//Unix
|
||||
var index = q.LastIndexOf('/');
|
||||
var index = term.LastIndexOf('/');
|
||||
|
||||
if (index > -1)
|
||||
{
|
||||
dirs = _diskProvider.GetDirectories(q.Substring(0, index + 1));
|
||||
dirs = _diskProvider.GetDirectories(term.Substring(0, index + 1));
|
||||
}
|
||||
}
|
||||
catch
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue