mirror of
https://github.com/Kareadita/Kavita.git
synced 2026-06-05 22:35:17 -04:00
Koreader Progress Sync for all files (#4323)
Co-authored-by: Amelia <77553571+Fesaa@users.noreply.github.com>
This commit is contained in:
@@ -89,6 +89,18 @@ public class StatsController(
|
||||
return Ok(await statService.GetPopularSeries());
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
/// Gets the top 5 most popular reading lists. Counts a reading list as active if a user has read at least some
|
||||
/// </summary>
|
||||
/// <returns></returns>
|
||||
[Authorize(PolicyGroups.AdminPolicy)]
|
||||
[HttpGet("popular-reading-list")]
|
||||
[ResponseCache(CacheProfileName = ResponseCacheProfiles.Statistics)]
|
||||
public async Task<ActionResult<IList<StatCount<SeriesDto>>>> GetPopularReadingList()
|
||||
{
|
||||
return Ok(await statService.GetPopularReadingList());
|
||||
}
|
||||
|
||||
[Authorize(PolicyGroups.AdminPolicy)]
|
||||
[HttpGet("popular-genres")]
|
||||
[ResponseCache(CacheProfileName = ResponseCacheProfiles.Statistics)]
|
||||
@@ -106,23 +118,13 @@ public class StatsController(
|
||||
}
|
||||
|
||||
[Authorize(PolicyGroups.AdminPolicy)]
|
||||
[HttpGet("popular-authors")]
|
||||
[HttpGet("popular-people")]
|
||||
[ResponseCache(CacheProfileName = ResponseCacheProfiles.Statistics)]
|
||||
public async Task<ActionResult<IList<StatCount<PersonDto>>>> GetPopularAuthors()
|
||||
public async Task<ActionResult<IList<StatCount<PersonDto>>>> GetPopularPeople(PersonRole role)
|
||||
{
|
||||
return Ok(await statService.GetPopularPerson(PersonRole.Writer));
|
||||
return Ok(await statService.GetPopularPerson(role));
|
||||
}
|
||||
|
||||
[Authorize(PolicyGroups.AdminPolicy)]
|
||||
[HttpGet("popular-artists")]
|
||||
[ResponseCache(CacheProfileName = ResponseCacheProfiles.Statistics)]
|
||||
public async Task<ActionResult<IList<StatCount<PersonDto>>>> GetPopularArtists()
|
||||
{
|
||||
return Ok(await statService.GetPopularPerson(PersonRole.CoverArtist));
|
||||
}
|
||||
|
||||
|
||||
|
||||
/// <summary>
|
||||
/// Top 5 most active readers for the given timeframe
|
||||
/// </summary>
|
||||
|
||||
Reference in New Issue
Block a user