mirror of
https://github.com/BinaryAlley/Nemera.git
synced 2026-12-02 06:01:10 +00:00
Adds real time media libraries scan progress update via SignalR
This commit is contained in:
1 parent
d70b2dcaa0
commit
e0d61802df
71 files changed
+1292
-131
No files matched your search
+11
@@ -114,6 +114,17 @@ public class LibraryManagementController : Controller
|
||||
return Json(new { success = true });
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the list of ongoing media library scans.
|
||||
/// </summary>
|
||||
/// <param name="cancellationToken">Cancellation token that can be used to stop the execution.</param>
|
||||
[HttpGet("api-get-running-library-scans")]
|
||||
public async Task<IActionResult> GetRunningLibraryScans(CancellationToken cancellationToken = default)
|
||||
{
|
||||
LibraryScanProgressModel[] response = await _apiHttpClient.GetAsync<LibraryScanProgressModel[]>($"libraries/scans/running/", cancellationToken).ConfigureAwait(false);
|
||||
return Json(new { success = true, data = response });
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Initiates the scan of all media libraries.
|
||||
/// </summary>
|
||||
|
||||
Reference in new issue
Block a user