mirror of
https://github.com/Readarr/Readarr
synced 2026-04-27 23:30:59 +02:00
Fixed: Reinstate total book count in author stats
This commit is contained in:
parent
fe13823b43
commit
3ab29eee60
3 changed files with 3 additions and 0 deletions
|
|
@ -7,6 +7,7 @@ public class AuthorStatistics : ResultSet
|
|||
{
|
||||
public int AuthorId { get; set; }
|
||||
public int BookCount { get; set; }
|
||||
public int TotalBookCount { get; set; }
|
||||
public int BookFileCount { get; set; }
|
||||
public long SizeOnDisk { get; set; }
|
||||
public List<BookStatistics> BookStatistics { get; set; }
|
||||
|
|
|
|||
|
|
@ -58,6 +58,7 @@ private AuthorStatistics MapAuthorStatistics(List<BookStatistics> bookStatistics
|
|||
{
|
||||
BookStatistics = bookStatistics,
|
||||
BookCount = bookStatistics.Sum(s => s.BookCount),
|
||||
TotalBookCount = bookStatistics.Sum(s => s.TotalBookCount),
|
||||
AuthorId = bookStatistics.First().AuthorId,
|
||||
BookFileCount = bookStatistics.Sum(s => s.BookFileCount),
|
||||
SizeOnDisk = bookStatistics.Sum(s => s.SizeOnDisk)
|
||||
|
|
|
|||
|
|
@ -35,6 +35,7 @@ public static AuthorStatisticsResource ToResource(this AuthorStatistics model)
|
|||
return new AuthorStatisticsResource
|
||||
{
|
||||
BookCount = model.BookCount,
|
||||
TotalBookCount = model.TotalBookCount,
|
||||
BookFileCount = model.BookFileCount,
|
||||
SizeOnDisk = model.SizeOnDisk
|
||||
};
|
||||
|
|
|
|||
Loading…
Reference in a new issue