mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-12-03 13:44:09 +01:00
Library stats page links to genres, authors, items #453, use overall days when hours > 10000
This commit is contained in:
1 parent
8be3bebee8
commit
f2d9de5a5f
3 files changed
+24
-11
No files matched your search
@@ -247,7 +247,8 @@ module.exports = {
|
||||
if (authorsMap[author.id]) authorsMap[author.id].count++
|
||||
else
|
||||
authorsMap[author.id] = {
|
||||
author: author.name,
|
||||
id: author.id,
|
||||
name: author.name,
|
||||
count: 1
|
||||
}
|
||||
})
|
||||
@@ -257,7 +258,7 @@ module.exports = {
|
||||
|
||||
getItemDurationStats(libraryItems) {
|
||||
var sorted = sort(libraryItems).desc(li => li.media.duration)
|
||||
var top10 = sorted.slice(0, 10).map(li => ({ title: li.media.metadata.title, duration: li.media.duration })).filter(i => i.duration > 0)
|
||||
var top10 = sorted.slice(0, 10).map(li => ({ id: li.id, title: li.media.metadata.title, duration: li.media.duration })).filter(i => i.duration > 0)
|
||||
var totalDuration = 0
|
||||
var numAudioTracks = 0
|
||||
libraryItems.forEach((li) => {
|
||||
|
||||
Reference in new issue
Block a user