mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-11-23 08:54:11 +01:00
Podcast home page shelves for currently listening episodes, newest episodes. Podcast episode card
This commit is contained in:
1 parent
84fb7ce8b3
commit
5d12cc3f23
10 files changed
+164
-100
No files matched your search
@@ -257,5 +257,9 @@ class Podcast {
|
||||
if (!episode) return 0
|
||||
return episode.duration
|
||||
}
|
||||
|
||||
getEpisode(episodeId) {
|
||||
return this.episodes.find(ep => ep.id == episodeId)
|
||||
}
|
||||
}
|
||||
module.exports = Podcast
|
||||
@@ -251,6 +251,11 @@ class User {
|
||||
})
|
||||
}
|
||||
|
||||
getAllMediaProgressForLibraryItem(libraryItemId) {
|
||||
if (!this.mediaProgress) return []
|
||||
return this.mediaProgress.filter(li => li.libraryItemId === libraryItemId)
|
||||
}
|
||||
|
||||
createUpdateMediaProgress(libraryItem, updatePayload, episodeId = null) {
|
||||
var itemProgress = this.mediaProgress.find(li => {
|
||||
if (episodeId && li.episodeId !== episodeId) return false
|
||||
|
||||
Reference in new issue
Block a user