diff --git a/components/cards/LazyBookCard.vue b/components/cards/LazyBookCard.vue index 44fbda38..2f8d98bf 100644 --- a/components/cards/LazyBookCard.vue +++ b/components/cards/LazyBookCard.vue @@ -6,13 +6,13 @@ -
#{{ volumeNumber }}
+#{{ seriesSequence }}
+{{ numEpisodes }}
- {{ displayTitle }} + {{ displayTitle }} #{{ seriesSequence }}
{{ displayAuthor }}
{{ displaySortLine }}
@@ -44,7 +44,7 @@ export default { default: 192 }, bookCoverAspectRatio: Number, - showVolumeNumber: Boolean, + showSequence: Boolean, bookshelfView: Number, bookMount: { // Book can be passed as prop or set with setEntity() @@ -96,6 +96,12 @@ export default { mediaMetadata() { return this.media.metadata || {} }, + mediaType() { + return this._libraryItem.mediaType + }, + isPodcast() { + return this.mediaType === 'podcast' + }, placeholderUrl() { return '/book_placeholder.jpg' }, @@ -149,8 +155,20 @@ export default { authorLF() { return this.mediaMetadata.authorNameLF || '' }, - volumeNumber() { - return this.mediaMetadata.volumeNumber || null + series() { + // Only included when filtering by series or collapse series + return this.mediaMetadata.series + }, + seriesSequence() { + return this.series ? this.series.sequence : null + }, + collapsedSeries() { + // Only added to item object when collapseSeries is enabled + return this._libraryItem.collapsedSeries + }, + booksInSeries() { + // Only added to item object when collapseSeries is enabled + return this.collapsedSeries ? this.collapsedSeries.numBooks : 0 }, displayTitle() { if (this.orderBy === 'media.metadata.title' && this.sortingIgnorePrefix && this.title.toLowerCase().startsWith('the ')) { @@ -303,7 +321,7 @@ export default { } else { var router = this.$router || this.$nuxt.$router if (router) { - if (this.booksInSeries) router.push(`/library/${this.libraryId}/series/${this.$encode(this.series)}`) + if (this.collapsedSeries) router.push(`/library/${this.libraryId}/series/${this.collapsedSeries.id}`) else router.push(`/item/${this.libraryItemId}`) } } diff --git a/components/home/BookshelfNavBar.vue b/components/home/BookshelfNavBar.vue index 54e1f94c..fe6fc5e8 100644 --- a/components/home/BookshelfNavBar.vue +++ b/components/home/BookshelfNavBar.vue @@ -1,17 +1,8 @@{{ totalEntities }} {{ entityTitle }}
{{ selectedSeriesName }} ({{ totalEntities }})
+ -