mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2025-05-31 20:25:34 -04:00
Merge remote-tracking branch 'remotes/upstream/master' into allow-mrss-item-enclosures-for-podcasts
This commit is contained in:
commit
bdd8e5bb58
@ -46,5 +46,10 @@ RUN apk del make python3 g++
|
|||||||
|
|
||||||
EXPOSE 80
|
EXPOSE 80
|
||||||
|
|
||||||
|
ENV PORT=80
|
||||||
|
ENV CONFIG_PATH="/config"
|
||||||
|
ENV METADATA_PATH="/metadata"
|
||||||
|
ENV SOURCE="docker"
|
||||||
|
|
||||||
ENTRYPOINT ["tini", "--"]
|
ENTRYPOINT ["tini", "--"]
|
||||||
CMD ["node", "index.js"]
|
CMD ["node", "index.js"]
|
||||||
|
@ -55,7 +55,7 @@
|
|||||||
@showPlayerQueueItems="showPlayerQueueItemsModal = true"
|
@showPlayerQueueItems="showPlayerQueueItemsModal = true"
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<modals-bookmarks-modal v-model="showBookmarksModal" :bookmarks="bookmarks" :current-time="bookmarkCurrentTime" :library-item-id="libraryItemId" @select="selectBookmark" />
|
<modals-bookmarks-modal v-model="showBookmarksModal" :bookmarks="bookmarks" :current-time="bookmarkCurrentTime" :playback-rate="currentPlaybackRate" :library-item-id="libraryItemId" @select="selectBookmark" />
|
||||||
|
|
||||||
<modals-sleep-timer-modal v-model="showSleepTimerModal" :timer-set="sleepTimerSet" :timer-type="sleepTimerType" :remaining="sleepTimerRemaining" :has-chapters="!!chapters.length" @set="setSleepTimer" @cancel="cancelSleepTimer" @increment="incrementSleepTimer" @decrement="decrementSleepTimer" />
|
<modals-sleep-timer-modal v-model="showSleepTimerModal" :timer-set="sleepTimerSet" :timer-type="sleepTimerType" :remaining="sleepTimerRemaining" :has-chapters="!!chapters.length" @set="setSleepTimer" @cancel="cancelSleepTimer" @increment="incrementSleepTimer" @decrement="decrementSleepTimer" />
|
||||||
|
|
||||||
|
@ -5,24 +5,26 @@
|
|||||||
<p class="text-3xl text-white truncate">{{ $strings.LabelYourBookmarks }}</p>
|
<p class="text-3xl text-white truncate">{{ $strings.LabelYourBookmarks }}</p>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<div ref="container" class="w-full rounded-lg bg-bg box-shadow-md overflow-y-auto overflow-x-hidden" style="max-height: 80vh">
|
<div v-if="show" class="w-full rounded-lg bg-bg box-shadow-md relative" style="max-height: 80vh">
|
||||||
<div v-if="show" class="w-full h-full">
|
<div v-if="bookmarks.length" class="h-full max-h-[calc(80vh-60px)] w-full relative overflow-y-auto overflow-x-hidden">
|
||||||
<template v-for="bookmark in bookmarks">
|
<template v-for="bookmark in bookmarks">
|
||||||
<modals-bookmarks-bookmark-item :key="bookmark.id" :highlight="currentTime === bookmark.time" :bookmark="bookmark" @click="clickBookmark" @update="submitUpdateBookmark" @delete="deleteBookmark" />
|
<modals-bookmarks-bookmark-item :key="bookmark.id" :highlight="currentTime === bookmark.time" :bookmark="bookmark" :playback-rate="playbackRate" @click="clickBookmark" @delete="deleteBookmark" />
|
||||||
</template>
|
</template>
|
||||||
<div v-if="!bookmarks.length" class="flex h-32 items-center justify-center">
|
</div>
|
||||||
<p class="text-xl">{{ $strings.MessageNoBookmarks }}</p>
|
<div v-else class="flex h-32 items-center justify-center">
|
||||||
</div>
|
<p class="text-xl">{{ $strings.MessageNoBookmarks }}</p>
|
||||||
<div v-if="!hideCreate" class="w-full h-px bg-white bg-opacity-10" />
|
</div>
|
||||||
<form v-if="!hideCreate" @submit.prevent="submitCreateBookmark">
|
|
||||||
<div v-show="canCreateBookmark" class="flex px-4 py-2 items-center text-center border-b border-white border-opacity-10 text-white text-opacity-80">
|
<div v-if="canCreateBookmark && !hideCreate" class="w-full border-t border-white/10">
|
||||||
|
<form @submit.prevent="submitCreateBookmark">
|
||||||
|
<div class="flex px-4 py-2 items-center text-center border-b border-white border-opacity-10 text-white text-opacity-80">
|
||||||
<div class="w-16 max-w-16 text-center">
|
<div class="w-16 max-w-16 text-center">
|
||||||
<p class="text-sm font-mono text-gray-400">
|
<p class="text-sm font-mono text-gray-400">
|
||||||
{{ this.$secondsToTimestamp(currentTime) }}
|
{{ this.$secondsToTimestamp(currentTime / playbackRate) }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex-grow px-2">
|
<div class="flex-grow px-2">
|
||||||
<ui-text-input v-model="newBookmarkTitle" placeholder="Note" class="w-full" />
|
<ui-text-input v-model="newBookmarkTitle" placeholder="Note" class="w-full h-10" />
|
||||||
</div>
|
</div>
|
||||||
<ui-btn type="submit" color="success" :padding-x="4" class="h-10"><span class="material-symbols text-2xl -mt-px">add</span></ui-btn>
|
<ui-btn type="submit" color="success" :padding-x="4" class="h-10"><span class="material-symbols text-2xl -mt-px">add</span></ui-btn>
|
||||||
</div>
|
</div>
|
||||||
@ -45,6 +47,7 @@ export default {
|
|||||||
default: 0
|
default: 0
|
||||||
},
|
},
|
||||||
libraryItemId: String,
|
libraryItemId: String,
|
||||||
|
playbackRate: Number,
|
||||||
hideCreate: Boolean
|
hideCreate: Boolean
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
@ -57,6 +60,7 @@ export default {
|
|||||||
watch: {
|
watch: {
|
||||||
show(newVal) {
|
show(newVal) {
|
||||||
if (newVal) {
|
if (newVal) {
|
||||||
|
this.selectedBookmark = null
|
||||||
this.showBookmarkTitleInput = false
|
this.showBookmarkTitleInput = false
|
||||||
this.newBookmarkTitle = ''
|
this.newBookmarkTitle = ''
|
||||||
}
|
}
|
||||||
@ -72,7 +76,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
canCreateBookmark() {
|
canCreateBookmark() {
|
||||||
return !this.bookmarks.find((bm) => bm.time === this.currentTime)
|
return !this.bookmarks.find((bm) => Math.abs(this.currentTime - bm.time) < 1)
|
||||||
},
|
},
|
||||||
dateFormat() {
|
dateFormat() {
|
||||||
return this.$store.state.serverSettings.dateFormat
|
return this.$store.state.serverSettings.dateFormat
|
||||||
@ -102,19 +106,6 @@ export default {
|
|||||||
clickBookmark(bm) {
|
clickBookmark(bm) {
|
||||||
this.$emit('select', bm)
|
this.$emit('select', bm)
|
||||||
},
|
},
|
||||||
submitUpdateBookmark(updatedBookmark) {
|
|
||||||
var bookmark = { ...updatedBookmark }
|
|
||||||
this.$axios
|
|
||||||
.$patch(`/api/me/item/${this.libraryItemId}/bookmark`, bookmark)
|
|
||||||
.then(() => {
|
|
||||||
this.$toast.success(this.$strings.ToastBookmarkUpdateSuccess)
|
|
||||||
})
|
|
||||||
.catch((error) => {
|
|
||||||
this.$toast.error(this.$strings.ToastFailedToUpdate)
|
|
||||||
console.error(error)
|
|
||||||
})
|
|
||||||
this.show = false
|
|
||||||
},
|
|
||||||
submitCreateBookmark() {
|
submitCreateBookmark() {
|
||||||
if (!this.newBookmarkTitle) {
|
if (!this.newBookmarkTitle) {
|
||||||
this.newBookmarkTitle = this.$formatDatetime(Date.now(), this.dateFormat, this.timeFormat)
|
this.newBookmarkTitle = this.$formatDatetime(Date.now(), this.dateFormat, this.timeFormat)
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="flex items-center px-4 py-4 justify-start relative bg-primary hover:bg-opacity-25" :class="wrapperClass" @click.stop="click" @mouseover="mouseover" @mouseleave="mouseleave">
|
<div class="flex items-center px-4 py-4 justify-start relative hover:bg-primary/10" :class="wrapperClass" @click.stop="click" @mouseover="mouseover" @mouseleave="mouseleave">
|
||||||
<div class="w-16 max-w-16 text-center">
|
<div class="w-16 max-w-16 text-center">
|
||||||
<p class="text-sm font-mono text-gray-400">
|
<p class="text-sm font-mono text-gray-400">
|
||||||
{{ this.$secondsToTimestamp(bookmark.time) }}
|
{{ this.$secondsToTimestamp(bookmark.time / playbackRate) }}
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="flex-grow overflow-hidden px-2">
|
<div class="flex-grow overflow-hidden px-2">
|
||||||
@ -10,7 +10,7 @@
|
|||||||
<form @submit.prevent="submitUpdate">
|
<form @submit.prevent="submitUpdate">
|
||||||
<div class="flex items-center">
|
<div class="flex items-center">
|
||||||
<div class="flex-grow pr-2">
|
<div class="flex-grow pr-2">
|
||||||
<ui-text-input v-model="newBookmarkTitle" placeholder="Note" class="w-full" />
|
<ui-text-input v-model="newBookmarkTitle" placeholder="Note" class="w-full h-10" />
|
||||||
</div>
|
</div>
|
||||||
<ui-btn type="submit" color="success" :padding-x="4" class="h-10"><span class="material-symbols text-2xl -mt-px">forward</span></ui-btn>
|
<ui-btn type="submit" color="success" :padding-x="4" class="h-10"><span class="material-symbols text-2xl -mt-px">forward</span></ui-btn>
|
||||||
<div class="pl-2 flex items-center">
|
<div class="pl-2 flex items-center">
|
||||||
@ -35,7 +35,8 @@ export default {
|
|||||||
type: Object,
|
type: Object,
|
||||||
default: () => {}
|
default: () => {}
|
||||||
},
|
},
|
||||||
highlight: Boolean
|
highlight: Boolean,
|
||||||
|
playbackRate: Number
|
||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
@ -83,11 +84,19 @@ export default {
|
|||||||
if (this.newBookmarkTitle === this.bookmark.title) {
|
if (this.newBookmarkTitle === this.bookmark.title) {
|
||||||
return this.cancelEditing()
|
return this.cancelEditing()
|
||||||
}
|
}
|
||||||
var bookmark = { ...this.bookmark }
|
const bookmark = { ...this.bookmark }
|
||||||
bookmark.title = this.newBookmarkTitle
|
bookmark.title = this.newBookmarkTitle
|
||||||
this.$emit('update', bookmark)
|
|
||||||
|
this.$axios
|
||||||
|
.$patch(`/api/me/item/${bookmark.libraryItemId}/bookmark`, bookmark)
|
||||||
|
.then(() => {
|
||||||
|
this.isEditing = false
|
||||||
|
})
|
||||||
|
.catch((error) => {
|
||||||
|
this.$toast.error(this.$strings.ToastFailedToUpdate)
|
||||||
|
console.error(error)
|
||||||
|
})
|
||||||
}
|
}
|
||||||
},
|
}
|
||||||
mounted() {}
|
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
@ -113,6 +113,10 @@ export default {
|
|||||||
return false
|
return false
|
||||||
})
|
})
|
||||||
console.log('updateResult', updateResult)
|
console.log('updateResult', updateResult)
|
||||||
|
} else if (!lastEpisodeCheck) {
|
||||||
|
this.$toast.error(this.$strings.ToastDateTimeInvalidOrIncomplete)
|
||||||
|
this.checkingNewEpisodes = false
|
||||||
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
this.$axios
|
this.$axios
|
||||||
|
@ -5,6 +5,9 @@
|
|||||||
<ui-checkbox v-model="enableAutoScan" @input="toggleEnableAutoScan" :label="$strings.LabelEnable" medium checkbox-bg="bg" label-class="pl-2 text-base md:text-lg" />
|
<ui-checkbox v-model="enableAutoScan" @input="toggleEnableAutoScan" :label="$strings.LabelEnable" medium checkbox-bg="bg" label-class="pl-2 text-base md:text-lg" />
|
||||||
</div>
|
</div>
|
||||||
<widgets-cron-expression-builder ref="cronExpressionBuilder" v-if="enableAutoScan" v-model="cronExpression" @input="updatedCron" />
|
<widgets-cron-expression-builder ref="cronExpressionBuilder" v-if="enableAutoScan" v-model="cronExpression" @input="updatedCron" />
|
||||||
|
<div v-else>
|
||||||
|
<p class="text-yellow-400 text-base">{{ $strings.MessageScheduleLibraryScanNote }}</p>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -170,6 +170,12 @@ export default {
|
|||||||
this.show = false
|
this.show = false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
libraryItemUpdated(libraryItem) {
|
||||||
|
const episode = libraryItem.media.episodes.find((e) => e.id === this.selectedEpisodeId)
|
||||||
|
if (episode) {
|
||||||
|
this.episodeItem = episode
|
||||||
|
}
|
||||||
|
},
|
||||||
hotkey(action) {
|
hotkey(action) {
|
||||||
if (action === this.$hotkeys.Modal.NEXT_PAGE) {
|
if (action === this.$hotkeys.Modal.NEXT_PAGE) {
|
||||||
this.goNextEpisode()
|
this.goNextEpisode()
|
||||||
@ -178,9 +184,15 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
registerListeners() {
|
registerListeners() {
|
||||||
|
if (this.libraryItem) {
|
||||||
|
this.$eventBus.$on(`${this.libraryItem.id}_updated`, this.libraryItemUpdated)
|
||||||
|
}
|
||||||
this.$eventBus.$on('modal-hotkey', this.hotkey)
|
this.$eventBus.$on('modal-hotkey', this.hotkey)
|
||||||
},
|
},
|
||||||
unregisterListeners() {
|
unregisterListeners() {
|
||||||
|
if (this.libraryItem) {
|
||||||
|
this.$eventBus.$on(`${this.libraryItem.id}_updated`, this.libraryItemUpdated)
|
||||||
|
}
|
||||||
this.$eventBus.$off('modal-hotkey', this.hotkey)
|
this.$eventBus.$off('modal-hotkey', this.hotkey)
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
<ui-dropdown v-model="newEpisode.episodeType" :label="$strings.LabelEpisodeType" :items="episodeTypes" small />
|
<ui-dropdown v-model="newEpisode.episodeType" :label="$strings.LabelEpisodeType" :items="episodeTypes" small />
|
||||||
</div>
|
</div>
|
||||||
<div class="w-2/5 p-1">
|
<div class="w-2/5 p-1">
|
||||||
<ui-text-input-with-label v-model="pubDateInput" @input="updatePubDate" type="datetime-local" :label="$strings.LabelPubDate" />
|
<ui-text-input-with-label v-model="pubDateInput" ref="pubdate" type="datetime-local" :label="$strings.LabelPubDate" @input="updatePubDate" />
|
||||||
</div>
|
</div>
|
||||||
<div class="w-full p-1">
|
<div class="w-full p-1">
|
||||||
<ui-text-input-with-label v-model="newEpisode.title" :label="$strings.LabelTitle" />
|
<ui-text-input-with-label v-model="newEpisode.title" :label="$strings.LabelTitle" />
|
||||||
@ -145,11 +145,18 @@ export default {
|
|||||||
return null
|
return null
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Check pubdate is valid if it is being updated. Cannot be set to null in the web client
|
||||||
|
if (this.newEpisode.pubDate === null && this.$refs.pubdate?.$refs?.input?.isInvalidDate) {
|
||||||
|
this.$toast.error(this.$strings.ToastDateTimeInvalidOrIncomplete)
|
||||||
|
return null
|
||||||
|
}
|
||||||
|
|
||||||
const updatedDetails = this.getUpdatePayload()
|
const updatedDetails = this.getUpdatePayload()
|
||||||
if (!Object.keys(updatedDetails).length) {
|
if (!Object.keys(updatedDetails).length) {
|
||||||
this.$toast.info(this.$strings.ToastNoUpdatesNecessary)
|
this.$toast.info(this.$strings.ToastNoUpdatesNecessary)
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
return this.updateDetails(updatedDetails)
|
return this.updateDetails(updatedDetails)
|
||||||
},
|
},
|
||||||
async updateDetails(updatedDetails) {
|
async updateDetails(updatedDetails) {
|
||||||
@ -163,13 +170,10 @@ export default {
|
|||||||
|
|
||||||
this.isProcessing = false
|
this.isProcessing = false
|
||||||
if (updateResult) {
|
if (updateResult) {
|
||||||
if (updateResult) {
|
this.$toast.success(this.$strings.ToastItemUpdateSuccess)
|
||||||
this.$toast.success(this.$strings.ToastItemUpdateSuccess)
|
return true
|
||||||
return true
|
|
||||||
} else {
|
|
||||||
this.$toast.info(this.$strings.MessageNoUpdatesWereNecessary)
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
<div class="absolute -top-10 lg:top-0 right-0 lg:right-2 flex items-center h-full">
|
<div class="absolute -top-10 lg:top-0 right-0 lg:right-2 flex items-center h-full">
|
||||||
<controls-playback-speed-control v-model="playbackRate" @input="setPlaybackRate" @change="playbackRateChanged" class="mx-2 block" />
|
<controls-playback-speed-control v-model="playbackRate" @input="setPlaybackRate" @change="playbackRateChanged" class="mx-2 block" />
|
||||||
|
|
||||||
<ui-tooltip direction="left" :text="$strings.LabelVolume">
|
<ui-tooltip direction="bottom" :text="$strings.LabelVolume">
|
||||||
<controls-volume-control ref="volumeControl" v-model="volume" @input="setVolume" class="mx-2 hidden sm:block" />
|
<controls-volume-control ref="volumeControl" v-model="volume" @input="setVolume" class="mx-2 hidden sm:block" />
|
||||||
</ui-tooltip>
|
</ui-tooltip>
|
||||||
|
|
||||||
|
@ -63,9 +63,6 @@ export default {
|
|||||||
dayOfWeekToday() {
|
dayOfWeekToday() {
|
||||||
return new Date().getDay()
|
return new Date().getDay()
|
||||||
},
|
},
|
||||||
firstWeekStart() {
|
|
||||||
return this.$addDaysToToday(-this.daysToShow)
|
|
||||||
},
|
|
||||||
dayLabels() {
|
dayLabels() {
|
||||||
return [
|
return [
|
||||||
{
|
{
|
||||||
@ -198,12 +195,25 @@ export default {
|
|||||||
let minValue = 0
|
let minValue = 0
|
||||||
|
|
||||||
const dates = []
|
const dates = []
|
||||||
for (let i = 0; i < this.daysToShow + 1; i++) {
|
|
||||||
const date = i === 0 ? this.firstWeekStart : this.$addDaysToDate(this.firstWeekStart, i)
|
const numDaysInTheLastYear = 52 * 7 + this.dayOfWeekToday
|
||||||
|
const firstDay = this.$addDaysToToday(-numDaysInTheLastYear)
|
||||||
|
for (let i = 0; i < numDaysInTheLastYear + 1; i++) {
|
||||||
|
const date = i === 0 ? firstDay : this.$addDaysToDate(firstDay, i)
|
||||||
const dateString = this.$formatJsDate(date, 'yyyy-MM-dd')
|
const dateString = this.$formatJsDate(date, 'yyyy-MM-dd')
|
||||||
|
|
||||||
|
if (this.daysListening[dateString] > 0) {
|
||||||
|
this.daysListenedInTheLastYear++
|
||||||
|
}
|
||||||
|
|
||||||
|
const visibleDayIndex = i - (numDaysInTheLastYear - this.daysToShow)
|
||||||
|
if (visibleDayIndex < 0) {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
const dateObj = {
|
const dateObj = {
|
||||||
col: Math.floor(i / 7),
|
col: Math.floor(visibleDayIndex / 7),
|
||||||
row: i % 7,
|
row: visibleDayIndex % 7,
|
||||||
date,
|
date,
|
||||||
dateString,
|
dateString,
|
||||||
datePretty: this.$formatJsDate(date, 'MMM d, yyyy'),
|
datePretty: this.$formatJsDate(date, 'MMM d, yyyy'),
|
||||||
@ -215,7 +225,6 @@ export default {
|
|||||||
dates.push(dateObj)
|
dates.push(dateObj)
|
||||||
|
|
||||||
if (dateObj.value > 0) {
|
if (dateObj.value > 0) {
|
||||||
this.daysListenedInTheLastYear++
|
|
||||||
if (dateObj.value > maxValue) maxValue = dateObj.value
|
if (dateObj.value > maxValue) maxValue = dateObj.value
|
||||||
if (!minValue || dateObj.value < minValue) minValue = dateObj.value
|
if (!minValue || dateObj.value < minValue) minValue = dateObj.value
|
||||||
}
|
}
|
||||||
|
@ -96,7 +96,7 @@ export default {
|
|||||||
return this.episode?.title || ''
|
return this.episode?.title || ''
|
||||||
},
|
},
|
||||||
episodeSubtitle() {
|
episodeSubtitle() {
|
||||||
return this.episode?.subtitle || ''
|
return this.episode?.subtitle || this.episode?.description || ''
|
||||||
},
|
},
|
||||||
episodeType() {
|
episodeType() {
|
||||||
return this.episode?.episodeType || ''
|
return this.episode?.episodeType || ''
|
||||||
|
@ -30,7 +30,7 @@
|
|||||||
<ui-text-input v-model="search" @input="inputUpdate" type="search" :placeholder="$strings.PlaceholderSearchEpisode" class="flex-grow mr-2 text-sm md:text-base" />
|
<ui-text-input v-model="search" @input="inputUpdate" type="search" :placeholder="$strings.PlaceholderSearchEpisode" class="flex-grow mr-2 text-sm md:text-base" />
|
||||||
</form>
|
</form>
|
||||||
</div>
|
</div>
|
||||||
<div class="relative min-h-[176px]">
|
<div class="relative min-h-44">
|
||||||
<template v-for="episode in totalEpisodes">
|
<template v-for="episode in totalEpisodes">
|
||||||
<div :key="episode" :id="`episode-${episode - 1}`" class="w-full h-44 px-2 py-3 overflow-hidden relative border-b border-white/10">
|
<div :key="episode" :id="`episode-${episode - 1}`" class="w-full h-44 px-2 py-3 overflow-hidden relative border-b border-white/10">
|
||||||
<!-- episode is mounted here -->
|
<!-- episode is mounted here -->
|
||||||
@ -39,7 +39,7 @@
|
|||||||
<div v-if="isSearching" class="w-full h-full absolute inset-0 flex justify-center py-12" :class="{ 'bg-black/50': totalEpisodes }">
|
<div v-if="isSearching" class="w-full h-full absolute inset-0 flex justify-center py-12" :class="{ 'bg-black/50': totalEpisodes }">
|
||||||
<ui-loading-indicator />
|
<ui-loading-indicator />
|
||||||
</div>
|
</div>
|
||||||
<div v-else-if="!totalEpisodes" class="h-44 flex items-center justify-center">
|
<div v-else-if="!totalEpisodes" id="no-episodes" class="h-44 flex items-center justify-center">
|
||||||
<p class="text-lg">{{ $strings.MessageNoEpisodes }}</p>
|
<p class="text-lg">{{ $strings.MessageNoEpisodes }}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@ -80,7 +80,8 @@ export default {
|
|||||||
episodeComponentRefs: {},
|
episodeComponentRefs: {},
|
||||||
windowHeight: 0,
|
windowHeight: 0,
|
||||||
episodesTableOffsetTop: 0,
|
episodesTableOffsetTop: 0,
|
||||||
episodeRowHeight: 176
|
episodeRowHeight: 44 * 4, // h-44,
|
||||||
|
currScrollTop: 0
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
@ -484,9 +485,8 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
scroll(evt) {
|
handleScroll() {
|
||||||
if (!evt?.target?.scrollTop) return
|
const scrollTop = this.currScrollTop
|
||||||
const scrollTop = Math.max(evt.target.scrollTop - this.episodesTableOffsetTop, 0)
|
|
||||||
let firstEpisodeIndex = Math.floor(scrollTop / this.episodeRowHeight)
|
let firstEpisodeIndex = Math.floor(scrollTop / this.episodeRowHeight)
|
||||||
let lastEpisodeIndex = Math.ceil((scrollTop + this.windowHeight) / this.episodeRowHeight)
|
let lastEpisodeIndex = Math.ceil((scrollTop + this.windowHeight) / this.episodeRowHeight)
|
||||||
lastEpisodeIndex = Math.min(this.totalEpisodes - 1, lastEpisodeIndex)
|
lastEpisodeIndex = Math.min(this.totalEpisodes - 1, lastEpisodeIndex)
|
||||||
@ -501,6 +501,12 @@ export default {
|
|||||||
})
|
})
|
||||||
this.mountEpisodes(firstEpisodeIndex, lastEpisodeIndex + 1)
|
this.mountEpisodes(firstEpisodeIndex, lastEpisodeIndex + 1)
|
||||||
},
|
},
|
||||||
|
scroll(evt) {
|
||||||
|
if (!evt?.target?.scrollTop) return
|
||||||
|
const scrollTop = Math.max(evt.target.scrollTop - this.episodesTableOffsetTop, 0)
|
||||||
|
this.currScrollTop = scrollTop
|
||||||
|
this.handleScroll()
|
||||||
|
},
|
||||||
initListeners() {
|
initListeners() {
|
||||||
const itemPageWrapper = document.getElementById('item-page-wrapper')
|
const itemPageWrapper = document.getElementById('item-page-wrapper')
|
||||||
if (itemPageWrapper) {
|
if (itemPageWrapper) {
|
||||||
@ -532,11 +538,24 @@ export default {
|
|||||||
this.episodesTableOffsetTop = (lazyEpisodesTableEl?.offsetTop || 0) + 64
|
this.episodesTableOffsetTop = (lazyEpisodesTableEl?.offsetTop || 0) + 64
|
||||||
|
|
||||||
this.windowHeight = window.innerHeight
|
this.windowHeight = window.innerHeight
|
||||||
this.episodesPerPage = Math.ceil(this.windowHeight / this.episodeRowHeight)
|
|
||||||
|
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.mountEpisodes(0, Math.min(this.episodesPerPage, this.totalEpisodes))
|
this.recalcEpisodeRowHeight()
|
||||||
|
this.episodesPerPage = Math.ceil(this.windowHeight / this.episodeRowHeight)
|
||||||
|
// Maybe update currScrollTop if items were removed
|
||||||
|
const itemPageWrapper = document.getElementById('item-page-wrapper')
|
||||||
|
const { scrollHeight, clientHeight } = itemPageWrapper
|
||||||
|
const maxScrollTop = scrollHeight - clientHeight
|
||||||
|
this.currScrollTop = Math.min(this.currScrollTop, maxScrollTop)
|
||||||
|
this.handleScroll()
|
||||||
})
|
})
|
||||||
|
},
|
||||||
|
recalcEpisodeRowHeight() {
|
||||||
|
const episodeRowEl = document.getElementById('episode-0') || document.getElementById('no-episodes')
|
||||||
|
if (episodeRowEl) {
|
||||||
|
const height = getComputedStyle(episodeRowEl).height
|
||||||
|
this.episodeRowHeight = parseInt(height) || this.episodeRowHeight
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
|
@ -1,24 +1,6 @@
|
|||||||
<template>
|
<template>
|
||||||
<div ref="wrapper" class="relative">
|
<div ref="wrapper" class="relative">
|
||||||
<input
|
<input :id="inputId" :name="inputName" ref="input" v-model="inputValue" :type="actualType" :step="step" :min="min" :readonly="readonly" :disabled="disabled" :placeholder="placeholder" dir="auto" class="rounded bg-primary text-gray-200 focus:bg-bg focus:outline-none border h-full w-full" :class="classList" @keyup="keyup" @change="change" @focus="focused" @blur="blurred" />
|
||||||
:id="inputId"
|
|
||||||
:name="inputName"
|
|
||||||
ref="input"
|
|
||||||
v-model="inputValue"
|
|
||||||
:type="actualType"
|
|
||||||
:step="step"
|
|
||||||
:min="min"
|
|
||||||
:readonly="readonly"
|
|
||||||
:disabled="disabled"
|
|
||||||
:placeholder="placeholder"
|
|
||||||
dir="auto"
|
|
||||||
class="rounded bg-primary text-gray-200 focus:border-gray-300 focus:bg-bg focus:outline-none border border-gray-600 h-full w-full"
|
|
||||||
:class="classList"
|
|
||||||
@keyup="keyup"
|
|
||||||
@change="change"
|
|
||||||
@focus="focused"
|
|
||||||
@blur="blurred"
|
|
||||||
/>
|
|
||||||
<div v-if="clearable && inputValue" class="absolute top-0 right-0 h-full px-2 flex items-center justify-center">
|
<div v-if="clearable && inputValue" class="absolute top-0 right-0 h-full px-2 flex items-center justify-center">
|
||||||
<span class="material-symbols text-gray-300 cursor-pointer" style="font-size: 1.1rem" @click.stop.prevent="clear">close</span>
|
<span class="material-symbols text-gray-300 cursor-pointer" style="font-size: 1.1rem" @click.stop.prevent="clear">close</span>
|
||||||
</div>
|
</div>
|
||||||
@ -65,7 +47,8 @@ export default {
|
|||||||
showPassword: false,
|
showPassword: false,
|
||||||
isHovering: false,
|
isHovering: false,
|
||||||
isFocused: false,
|
isFocused: false,
|
||||||
hasCopied: false
|
hasCopied: false,
|
||||||
|
isInvalidDate: false
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
@ -84,6 +67,10 @@ export default {
|
|||||||
if (this.noSpinner) _list.push('no-spinner')
|
if (this.noSpinner) _list.push('no-spinner')
|
||||||
if (this.textCenter) _list.push('text-center')
|
if (this.textCenter) _list.push('text-center')
|
||||||
if (this.customInputClass) _list.push(this.customInputClass)
|
if (this.customInputClass) _list.push(this.customInputClass)
|
||||||
|
|
||||||
|
if (this.isInvalidDate) _list.push('border-error')
|
||||||
|
else _list.push('focus:border-gray-300 border-gray-600')
|
||||||
|
|
||||||
return _list.join(' ')
|
return _list.join(' ')
|
||||||
},
|
},
|
||||||
actualType() {
|
actualType() {
|
||||||
@ -118,6 +105,14 @@ export default {
|
|||||||
},
|
},
|
||||||
keyup(e) {
|
keyup(e) {
|
||||||
this.$emit('keyup', e)
|
this.$emit('keyup', e)
|
||||||
|
|
||||||
|
if (this.type === 'datetime-local') {
|
||||||
|
if (e.target.validity?.badInput) {
|
||||||
|
this.isInvalidDate = true
|
||||||
|
} else {
|
||||||
|
this.isInvalidDate = false
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
blur() {
|
blur() {
|
||||||
if (this.$refs.input) this.$refs.input.blur()
|
if (this.$refs.input) this.$refs.input.blur()
|
||||||
|
@ -1,9 +1,10 @@
|
|||||||
<template>
|
<template>
|
||||||
<div class="w-full">
|
<div class="w-full">
|
||||||
<slot>
|
<slot>
|
||||||
<label :for="identifier" class="px-1 text-sm font-semibold" :class="{ 'text-gray-400': disabled }"
|
<label :for="identifier" class="px-1 text-sm font-semibold" :class="{ 'text-gray-400': disabled }">
|
||||||
>{{ label }}<em v-if="note" class="font-normal text-xs pl-2">{{ note }}</em></label
|
{{ label }}
|
||||||
>
|
<em v-if="note" class="font-normal text-xs pl-2">{{ note }}</em>
|
||||||
|
</label>
|
||||||
</slot>
|
</slot>
|
||||||
<ui-text-input :placeholder="placeholder || label" :inputId="identifier" ref="input" v-model="inputValue" :disabled="disabled" :readonly="readonly" :type="type" class="w-full" :class="inputClass" @blur="inputBlurred" />
|
<ui-text-input :placeholder="placeholder || label" :inputId="identifier" ref="input" v-model="inputValue" :disabled="disabled" :readonly="readonly" :type="type" class="w-full" :class="inputClass" @blur="inputBlurred" />
|
||||||
</div>
|
</div>
|
||||||
@ -57,4 +58,4 @@ export default {
|
|||||||
},
|
},
|
||||||
mounted() {}
|
mounted() {}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
@ -249,11 +249,33 @@ export default {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
return target
|
return target
|
||||||
|
},
|
||||||
|
enableBreakParagraphOnReturn() {
|
||||||
|
// Trix works with divs by default, we want paragraphs instead
|
||||||
|
Trix.config.blockAttributes.default.tagName = 'p'
|
||||||
|
// Enable break paragraph on Enter (Shift + Enter will still create a line break)
|
||||||
|
Trix.config.blockAttributes.default.breakOnReturn = true
|
||||||
|
|
||||||
|
// Hack to fix buggy paragraph breaks
|
||||||
|
// Copied from https://github.com/basecamp/trix/issues/680#issuecomment-735742942
|
||||||
|
Trix.Block.prototype.breaksOnReturn = function () {
|
||||||
|
const attr = this.getLastAttribute()
|
||||||
|
const config = Trix.getBlockConfig(attr ? attr : 'default')
|
||||||
|
return config ? config.breakOnReturn : false
|
||||||
|
}
|
||||||
|
Trix.LineBreakInsertion.prototype.shouldInsertBlockBreak = function () {
|
||||||
|
if (this.block.hasAttributes() && this.block.isListItem() && !this.block.isEmpty()) {
|
||||||
|
return this.startLocation.offset > 0
|
||||||
|
} else {
|
||||||
|
return !this.shouldBreakFormattedBlock() ? this.breaksOnReturn : false
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
/** Override editor configuration */
|
/** Override editor configuration */
|
||||||
this.overrideConfig(this.config)
|
this.overrideConfig(this.config)
|
||||||
|
this.enableBreakParagraphOnReturn()
|
||||||
/** Check if editor read-only mode is required */
|
/** Check if editor read-only mode is required */
|
||||||
this.decorateDisabledEditor(this.disabledEditor)
|
this.decorateDisabledEditor(this.disabledEditor)
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
@ -283,4 +305,4 @@ export default {
|
|||||||
.trix_container .trix-content {
|
.trix_container .trix-content {
|
||||||
background-color: white;
|
background-color: white;
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
188
client/cypress/tests/utils/ElapsedPrettyExtended.cy.js
Normal file
188
client/cypress/tests/utils/ElapsedPrettyExtended.cy.js
Normal file
@ -0,0 +1,188 @@
|
|||||||
|
import Vue from 'vue'
|
||||||
|
import '@/plugins/utils'
|
||||||
|
|
||||||
|
// This is the actual function that is being tested
|
||||||
|
const elapsedPrettyExtended = Vue.prototype.$elapsedPrettyExtended
|
||||||
|
|
||||||
|
// Helper function to convert days, hours, minutes, seconds to total seconds
|
||||||
|
function DHMStoSeconds(days, hours, minutes, seconds) {
|
||||||
|
return seconds + minutes * 60 + hours * 3600 + days * 86400
|
||||||
|
}
|
||||||
|
|
||||||
|
describe('$elapsedPrettyExtended', () => {
|
||||||
|
describe('function is on the Vue Prototype', () => {
|
||||||
|
it('exists as a function on Vue.prototype', () => {
|
||||||
|
expect(Vue.prototype.$elapsedPrettyExtended).to.exist
|
||||||
|
expect(Vue.prototype.$elapsedPrettyExtended).to.be.a('function')
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('param default values', () => {
|
||||||
|
const testSeconds = DHMStoSeconds(0, 25, 1, 5) // 25h 1m 5s = 90065 seconds
|
||||||
|
|
||||||
|
it('uses useDays=true showSeconds=true by default', () => {
|
||||||
|
expect(elapsedPrettyExtended(testSeconds)).to.equal('1d 1h 1m 5s')
|
||||||
|
})
|
||||||
|
|
||||||
|
it('only useDays=false overrides useDays but keeps showSeconds=true', () => {
|
||||||
|
expect(elapsedPrettyExtended(testSeconds, false)).to.equal('25h 1m 5s')
|
||||||
|
})
|
||||||
|
|
||||||
|
it('explicit useDays=false showSeconds=false overrides both', () => {
|
||||||
|
expect(elapsedPrettyExtended(testSeconds, false, false)).to.equal('25h 1m')
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('useDays=false showSeconds=true', () => {
|
||||||
|
const useDaysFalse = false
|
||||||
|
const showSecondsTrue = true
|
||||||
|
const testCases = [
|
||||||
|
[[0, 0, 0, 0], '', '0s -> ""'],
|
||||||
|
[[0, 1, 0, 1], '1h 1s', '1h 1s -> 1h 1s'],
|
||||||
|
[[0, 25, 0, 1], '25h 1s', '25h 1s -> 25h 1s']
|
||||||
|
]
|
||||||
|
|
||||||
|
testCases.forEach(([dhms, expected, description]) => {
|
||||||
|
it(description, () => {
|
||||||
|
expect(elapsedPrettyExtended(DHMStoSeconds(...dhms), useDaysFalse, showSecondsTrue)).to.equal(expected)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('useDays=true showSeconds=true', () => {
|
||||||
|
const useDaysTrue = true
|
||||||
|
const showSecondsTrue = true
|
||||||
|
const testCases = [
|
||||||
|
[[0, 0, 0, 0], '', '0s -> ""'],
|
||||||
|
[[0, 1, 0, 1], '1h 1s', '1h 1s -> 1h 1s'],
|
||||||
|
[[0, 25, 0, 1], '1d 1h 1s', '25h 1s -> 1d 1h 1s']
|
||||||
|
]
|
||||||
|
|
||||||
|
testCases.forEach(([dhms, expected, description]) => {
|
||||||
|
it(description, () => {
|
||||||
|
expect(elapsedPrettyExtended(DHMStoSeconds(...dhms), useDaysTrue, showSecondsTrue)).to.equal(expected)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('useDays=true showSeconds=false', () => {
|
||||||
|
const useDaysTrue = true
|
||||||
|
const showSecondsFalse = false
|
||||||
|
const testCases = [
|
||||||
|
[[0, 0, 0, 0], '', '0s -> ""'],
|
||||||
|
[[0, 1, 0, 0], '1h', '1h -> 1h'],
|
||||||
|
[[0, 1, 0, 1], '1h', '1h 1s -> 1h'],
|
||||||
|
[[0, 1, 1, 0], '1h 1m', '1h 1m -> 1h 1m'],
|
||||||
|
[[0, 25, 0, 0], '1d 1h', '25h -> 1d 1h'],
|
||||||
|
[[0, 25, 0, 1], '1d 1h', '25h 1s -> 1d 1h'],
|
||||||
|
[[2, 0, 0, 0], '2d', '2d -> 2d']
|
||||||
|
]
|
||||||
|
|
||||||
|
testCases.forEach(([dhms, expected, description]) => {
|
||||||
|
it(description, () => {
|
||||||
|
expect(elapsedPrettyExtended(DHMStoSeconds(...dhms), useDaysTrue, showSecondsFalse)).to.equal(expected)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('rounding useDays=true showSeconds=true', () => {
|
||||||
|
const useDaysTrue = true
|
||||||
|
const showSecondsTrue = true
|
||||||
|
const testCases = [
|
||||||
|
// Seconds rounding
|
||||||
|
[[0, 0, 0, 1], '1s', '1s -> 1s'],
|
||||||
|
[[0, 0, 0, 29.9], '30s', '29.9s -> 30s'],
|
||||||
|
[[0, 0, 0, 30], '30s', '30s -> 30s'],
|
||||||
|
[[0, 0, 0, 30.1], '30s', '30.1s -> 30s'],
|
||||||
|
[[0, 0, 0, 59.4], '59s', '59.4s -> 59s'],
|
||||||
|
[[0, 0, 0, 59.5], '1m', '59.5s -> 1m'],
|
||||||
|
|
||||||
|
// Minutes rounding
|
||||||
|
[[0, 0, 59, 29], '59m 29s', '59m 29s -> 59m 29s'],
|
||||||
|
[[0, 0, 59, 30], '59m 30s', '59m 30s -> 59m 30s'],
|
||||||
|
[[0, 0, 59, 59.5], '1h', '59m 59.5s -> 1h'],
|
||||||
|
|
||||||
|
// Hours rounding
|
||||||
|
[[0, 23, 59, 29], '23h 59m 29s', '23h 59m 29s -> 23h 59m 29s'],
|
||||||
|
[[0, 23, 59, 30], '23h 59m 30s', '23h 59m 30s -> 23h 59m 30s'],
|
||||||
|
[[0, 23, 59, 59.5], '1d', '23h 59m 59.5s -> 1d'],
|
||||||
|
|
||||||
|
// The actual bug case
|
||||||
|
[[44, 23, 59, 30], '44d 23h 59m 30s', '44d 23h 59m 30s -> 44d 23h 59m 30s']
|
||||||
|
]
|
||||||
|
|
||||||
|
testCases.forEach(([dhms, expected, description]) => {
|
||||||
|
it(description, () => {
|
||||||
|
expect(elapsedPrettyExtended(DHMStoSeconds(...dhms), useDaysTrue, showSecondsTrue)).to.equal(expected)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('rounding useDays=true showSeconds=false', () => {
|
||||||
|
const useDaysTrue = true
|
||||||
|
const showSecondsFalse = false
|
||||||
|
const testCases = [
|
||||||
|
// Seconds rounding - these cases changed behavior from original
|
||||||
|
[[0, 0, 0, 1], '', '1s -> ""'],
|
||||||
|
[[0, 0, 0, 29.9], '', '29.9s -> ""'],
|
||||||
|
[[0, 0, 0, 30], '', '30s -> ""'],
|
||||||
|
[[0, 0, 0, 30.1], '', '30.1s -> ""'],
|
||||||
|
[[0, 0, 0, 59.4], '', '59.4s -> ""'],
|
||||||
|
[[0, 0, 0, 59.5], '1m', '59.5s -> 1m'],
|
||||||
|
// This is unexpected behavior, but it's consistent with the original behavior
|
||||||
|
// We preserved the test case, to document the current behavior
|
||||||
|
// - with showSeconds=false,
|
||||||
|
// one might expect: 1m 29.5s --round(1.4901m)-> 1m
|
||||||
|
// actual implementation: 1h 29.5s --roundSeconds-> 1h 30s --roundMinutes-> 2m
|
||||||
|
// So because of the separate rounding of seconds, and then minutes, it returns 2m
|
||||||
|
[[0, 0, 1, 29.5], '2m', '1m 29.5s -> 2m'],
|
||||||
|
|
||||||
|
// Minutes carry - actual bug fixes below
|
||||||
|
[[0, 0, 59, 29], '59m', '59m 29s -> 59m'],
|
||||||
|
[[0, 0, 59, 30], '1h', '59m 30s -> 1h'], // This was an actual bug, used to return 60m
|
||||||
|
[[0, 0, 59, 59.5], '1h', '59m 59.5s -> 1h'],
|
||||||
|
|
||||||
|
// Hours carry
|
||||||
|
[[0, 23, 59, 29], '23h 59m', '23h 59m 29s -> 23h 59m'],
|
||||||
|
[[0, 23, 59, 30], '1d', '23h 59m 30s -> 1d'], // This was an actual bug, used to return 23h 60m
|
||||||
|
[[0, 23, 59, 59.5], '1d', '23h 59m 59.5s -> 1d'],
|
||||||
|
|
||||||
|
// The actual bug case
|
||||||
|
[[44, 23, 59, 30], '45d', '44d 23h 59m 30s -> 45d'] // This was an actual bug, used to return 44d 23h 60m
|
||||||
|
]
|
||||||
|
|
||||||
|
testCases.forEach(([dhms, expected, description]) => {
|
||||||
|
it(description, () => {
|
||||||
|
expect(elapsedPrettyExtended(DHMStoSeconds(...dhms), useDaysTrue, showSecondsFalse)).to.equal(expected)
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
describe('empty values', () => {
|
||||||
|
const paramCombos = [
|
||||||
|
// useDays, showSeconds, description
|
||||||
|
[true, true, 'with days and seconds'],
|
||||||
|
[true, false, 'with days, no seconds'],
|
||||||
|
[false, true, 'no days, with seconds'],
|
||||||
|
[false, false, 'no days, no seconds']
|
||||||
|
]
|
||||||
|
|
||||||
|
const emptyInputs = [
|
||||||
|
// input, description
|
||||||
|
[null, 'null input'],
|
||||||
|
[undefined, 'undefined input'],
|
||||||
|
[0, 'zero'],
|
||||||
|
[0.49, 'rounds to zero'] // Just under rounding threshold
|
||||||
|
]
|
||||||
|
|
||||||
|
paramCombos.forEach(([useDays, showSeconds, paramDesc]) => {
|
||||||
|
describe(paramDesc, () => {
|
||||||
|
emptyInputs.forEach(([input, desc]) => {
|
||||||
|
it(desc, () => {
|
||||||
|
expect(elapsedPrettyExtended(input, useDays, showSeconds)).to.equal('')
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
||||||
|
})
|
@ -1,6 +1,6 @@
|
|||||||
const pkg = require('./package.json')
|
const pkg = require('./package.json')
|
||||||
|
|
||||||
const routerBasePath = process.env.ROUTER_BASE_PATH || ''
|
const routerBasePath = process.env.ROUTER_BASE_PATH || '/audiobookshelf'
|
||||||
const serverHostUrl = process.env.NODE_ENV === 'production' ? '' : 'http://localhost:3333'
|
const serverHostUrl = process.env.NODE_ENV === 'production' ? '' : 'http://localhost:3333'
|
||||||
const serverPaths = ['api/', 'public/', 'hls/', 'auth/', 'feed/', 'status', 'login', 'logout', 'init']
|
const serverPaths = ['api/', 'public/', 'hls/', 'auth/', 'feed/', 'status', 'login', 'logout', 'init']
|
||||||
const proxy = Object.fromEntries(serverPaths.map((path) => [`${routerBasePath}/${path}`, { target: process.env.NODE_ENV !== 'production' ? serverHostUrl : '/' }]))
|
const proxy = Object.fromEntries(serverPaths.map((path) => [`${routerBasePath}/${path}`, { target: process.env.NODE_ENV !== 'production' ? serverHostUrl : '/' }]))
|
||||||
|
4
client/package-lock.json
generated
4
client/package-lock.json
generated
@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "audiobookshelf-client",
|
"name": "audiobookshelf-client",
|
||||||
"version": "2.17.7",
|
"version": "2.18.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "audiobookshelf-client",
|
"name": "audiobookshelf-client",
|
||||||
"version": "2.17.7",
|
"version": "2.18.0",
|
||||||
"license": "ISC",
|
"license": "ISC",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@nuxtjs/axios": "^5.13.6",
|
"@nuxtjs/axios": "^5.13.6",
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "audiobookshelf-client",
|
"name": "audiobookshelf-client",
|
||||||
"version": "2.17.7",
|
"version": "2.18.0",
|
||||||
"buildNumber": 1,
|
"buildNumber": 1,
|
||||||
"description": "Self-hosted audiobook and podcast client",
|
"description": "Self-hosted audiobook and podcast client",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
|
@ -141,7 +141,7 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<modals-podcast-episode-feed v-model="showPodcastEpisodeFeed" :library-item="libraryItem" :episodes="podcastFeedEpisodes" />
|
<modals-podcast-episode-feed v-model="showPodcastEpisodeFeed" :library-item="libraryItem" :episodes="podcastFeedEpisodes" />
|
||||||
<modals-bookmarks-modal v-model="showBookmarksModal" :bookmarks="bookmarks" :library-item-id="libraryItemId" hide-create @select="selectBookmark" />
|
<modals-bookmarks-modal v-model="showBookmarksModal" :bookmarks="bookmarks" :playback-rate="1" :library-item-id="libraryItemId" hide-create @select="selectBookmark" />
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
|
@ -69,17 +69,22 @@ Vue.prototype.$elapsedPrettyExtended = (seconds, useDays = true, showSeconds = t
|
|||||||
let hours = Math.floor(minutes / 60)
|
let hours = Math.floor(minutes / 60)
|
||||||
minutes -= hours * 60
|
minutes -= hours * 60
|
||||||
|
|
||||||
|
// Handle rollovers before days calculation
|
||||||
|
if (minutes && seconds && !showSeconds) {
|
||||||
|
if (seconds >= 30) minutes++
|
||||||
|
if (minutes >= 60) {
|
||||||
|
hours++ // Increment hours if minutes roll over
|
||||||
|
minutes -= 60 // adjust minutes
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Now calculate days with the final hours value
|
||||||
let days = 0
|
let days = 0
|
||||||
if (useDays || Math.floor(hours / 24) >= 100) {
|
if (useDays || Math.floor(hours / 24) >= 100) {
|
||||||
days = Math.floor(hours / 24)
|
days = Math.floor(hours / 24)
|
||||||
hours -= days * 24
|
hours -= days * 24
|
||||||
}
|
}
|
||||||
|
|
||||||
// If not showing seconds then round minutes up
|
|
||||||
if (minutes && seconds && !showSeconds) {
|
|
||||||
if (seconds >= 30) minutes++
|
|
||||||
}
|
|
||||||
|
|
||||||
const strs = []
|
const strs = []
|
||||||
if (days) strs.push(`${days}d`)
|
if (days) strs.push(`${days}d`)
|
||||||
if (hours) strs.push(`${hours}h`)
|
if (hours) strs.push(`${hours}h`)
|
||||||
|
@ -1 +1,117 @@
|
|||||||
{}
|
{
|
||||||
|
"ButtonAdd": "Дадаць",
|
||||||
|
"ButtonAddChapters": "Дадаць раздзелы",
|
||||||
|
"ButtonAddDevice": "Дадаць прыладу",
|
||||||
|
"ButtonAddLibrary": "Дадаць бібліятэку",
|
||||||
|
"ButtonAddPodcasts": "Дадаць падкасты",
|
||||||
|
"ButtonAddUser": "Дадаць карыстальніка",
|
||||||
|
"ButtonAddYourFirstLibrary": "Дадайце сваю першую бібліятэку",
|
||||||
|
"ButtonApply": "Ужыць",
|
||||||
|
"ButtonApplyChapters": "Ужыць раздзелы",
|
||||||
|
"ButtonAuthors": "Аўтары",
|
||||||
|
"ButtonBack": "Назад",
|
||||||
|
"ButtonBrowseForFolder": "Знайсці тэчку",
|
||||||
|
"ButtonCancel": "Адмяніць",
|
||||||
|
"ButtonCancelEncode": "Адмяніць кадзіраванне",
|
||||||
|
"ButtonChangeRootPassword": "Зменіце Root пароль",
|
||||||
|
"ButtonCheckAndDownloadNewEpisodes": "Праверыць і спампаваць новыя эпізоды",
|
||||||
|
"ButtonChooseAFolder": "Выбраць тэчку",
|
||||||
|
"ButtonChooseFiles": "Выбраць файлы",
|
||||||
|
"ButtonClearFilter": "Ачысціць фільтр",
|
||||||
|
"ButtonCloseFeed": "Закрыць стужку",
|
||||||
|
"ButtonCloseSession": "Закрыць адкрыты сеанс",
|
||||||
|
"ButtonCollections": "Калекцыі",
|
||||||
|
"ButtonConfigureScanner": "Наладзіць сканер",
|
||||||
|
"ButtonCreate": "Ствараць",
|
||||||
|
"ButtonCreateBackup": "Стварыць рэзервовую копію",
|
||||||
|
"ButtonDelete": "Выдаліць",
|
||||||
|
"ButtonDownloadQueue": "Чарга",
|
||||||
|
"ButtonEdit": "Рэдагаваць",
|
||||||
|
"ButtonEditChapters": "Рэдагаваць раздзелы",
|
||||||
|
"ButtonEditPodcast": "Рэдагаваць падкаст",
|
||||||
|
"ButtonEnable": "Уключыць",
|
||||||
|
"ButtonFireAndFail": "Агонь і няўдача",
|
||||||
|
"ButtonFireOnTest": "Тэст на вогнеўстойлівасць",
|
||||||
|
"ButtonForceReScan": "Прымусовае паўторнае сканаванне",
|
||||||
|
"ButtonFullPath": "Поўны шлях",
|
||||||
|
"ButtonHide": "Схаваць",
|
||||||
|
"ButtonIssues": "Праблемы",
|
||||||
|
"ButtonJumpBackward": "Перайсці назад",
|
||||||
|
"ButtonJumpForward": "Перайсці наперад",
|
||||||
|
"ButtonLibrary": "Бібліятэка",
|
||||||
|
"ButtonLogout": "Выйсці",
|
||||||
|
"ButtonLookup": "",
|
||||||
|
"ButtonMapChapterTitles": "Супаставіць назвы раздзелаў",
|
||||||
|
"ButtonMatchAllAuthors": "Супадзенне ўсіх аўтараў",
|
||||||
|
"ButtonNevermind": "Няважна",
|
||||||
|
"ButtonNext": "Далей",
|
||||||
|
"ButtonNextChapter": "Наступны раздзел",
|
||||||
|
"ButtonNextItemInQueue": "Наступны элемент у чарзе",
|
||||||
|
"ButtonOk": "Добра",
|
||||||
|
"ButtonOpenFeed": "Адкрыць стужку",
|
||||||
|
"ButtonOpenManager": "Адкрыць менеджар",
|
||||||
|
"ButtonPause": "Паўза",
|
||||||
|
"ButtonPlay": "Прайграць",
|
||||||
|
"ButtonPlayAll": "Прайграць усё",
|
||||||
|
"ButtonPlaying": "Прайграваецца",
|
||||||
|
"ButtonPlaylists": "Плэйлісты",
|
||||||
|
"ButtonPrevious": "Папярэдні",
|
||||||
|
"ButtonPreviousChapter": "Папярэдні раздзел",
|
||||||
|
"ButtonProbeAudioFile": "Праверыць аўдыяфайл",
|
||||||
|
"ButtonPurgeAllCache": "Ачысціць увесь кэш",
|
||||||
|
"ButtonPurgeItemsCache": "Ачысціць кэш элементаў",
|
||||||
|
"ButtonQueueAddItem": "Дадаць у чаргу",
|
||||||
|
"ButtonQueueRemoveItem": "Выдаліць з чаргі",
|
||||||
|
"ButtonQuickEmbed": "Хуткае ўбудаванне",
|
||||||
|
"ButtonQuickEmbedMetadata": "Хуткае ўбудаванне метаданых",
|
||||||
|
"ButtonQuickMatch": "Хуткі пошук",
|
||||||
|
"ButtonReScan": "Паўторнае сканаванне",
|
||||||
|
"ButtonRead": "Чытаць",
|
||||||
|
"ButtonRefresh": "Абнавіць",
|
||||||
|
"ButtonRemove": "Выдаліць",
|
||||||
|
"ButtonRemoveAll": "Выдаліць усе",
|
||||||
|
"ButtonRemoveAllLibraryItems": "Выдаліць усе элементы бібліятэкі",
|
||||||
|
"ButtonReset": "Скінуць",
|
||||||
|
"ButtonResetToDefault": "Скінуць па змаўчанні",
|
||||||
|
"ButtonRestore": "Аднавіць",
|
||||||
|
"ButtonSave": "Захаваць",
|
||||||
|
"ButtonSaveAndClose": "Захаваць і зачыніць",
|
||||||
|
"ButtonSaveTracklist": "Захаваць спіс трэкаў",
|
||||||
|
"ButtonScan": "Сканаваць",
|
||||||
|
"ButtonScanLibrary": "Сканіраваць бібліятэку",
|
||||||
|
"ButtonScrollLeft": "Пракруціць улева",
|
||||||
|
"ButtonScrollRight": "Пракруціць направа",
|
||||||
|
"ButtonSearch": "Пошук",
|
||||||
|
"ButtonSelectFolderPath": "Выбраць шлях да тэчкі",
|
||||||
|
"ButtonSeries": "Серыі",
|
||||||
|
"ButtonSetChaptersFromTracks": "Усталяваць раздзелы з трэкаў",
|
||||||
|
"ButtonShare": "Падзяліцца",
|
||||||
|
"ButtonStartM4BEncode": "Пачаць кадзіраванне ў M4B",
|
||||||
|
"ButtonStartMetadataEmbed": "Пачаць убудаванне метаданых",
|
||||||
|
"ButtonStats": "Статыстыка",
|
||||||
|
"ButtonSubmit": "Адправіць",
|
||||||
|
"ButtonTest": "Тэст",
|
||||||
|
"ButtonUnlinkOpenId": "Адвязаць OpenID",
|
||||||
|
"ButtonUpload": "Загрузіць",
|
||||||
|
"ButtonUploadBackup": "Загрузіць рэзервовую копію",
|
||||||
|
"ButtonUploadCover": "Загрузіць вокладку",
|
||||||
|
"ButtonUploadOPMLFile": "Загрузіць OPML файл",
|
||||||
|
"ButtonUserDelete": "Выдаліць карыстальніка {0}",
|
||||||
|
"ButtonUserEdit": "Рэдагаваць карыстальніка {0}",
|
||||||
|
"ButtonViewAll": "Прагледзець усе",
|
||||||
|
"ButtonYes": "Так",
|
||||||
|
"HeaderAccount": "Уліковы запіс",
|
||||||
|
"HeaderAddCustomMetadataProvider": "Дадаць карыстальніцкага пастаўшчыка метаданных",
|
||||||
|
"HeaderAppriseNotificationSettings": "Налады апавяшчэнняў Apprise",
|
||||||
|
"HeaderAudiobookTools": "Сродкі кіравання файламі аўдыякніг",
|
||||||
|
"HeaderAuthentication": "Аўтэнтыфікацыя",
|
||||||
|
"HeaderBackups": "Рэзервовыя копіі",
|
||||||
|
"HeaderChangePassword": "Змяніць пароль",
|
||||||
|
"HeaderChapters": "Раздзелы",
|
||||||
|
"HeaderChooseAFolder": "Выбраць тэчку",
|
||||||
|
"HeaderCollection": "Калекцыя",
|
||||||
|
"HeaderCollectionItems": "Элементы калекцыі",
|
||||||
|
"HeaderCover": "Вокладка",
|
||||||
|
"HeaderCurrentDownloads": "Бягучыя загрузкі",
|
||||||
|
"HeaderCustomMessageOnLogin": "Карыстальніцкае паведамленне пры ўваходзе"
|
||||||
|
}
|
||||||
|
@ -725,7 +725,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Неуспешно създаване на отметка",
|
"ToastBookmarkCreateFailed": "Неуспешно създаване на отметка",
|
||||||
"ToastBookmarkCreateSuccess": "Отметката е създадена",
|
"ToastBookmarkCreateSuccess": "Отметката е създадена",
|
||||||
"ToastBookmarkRemoveSuccess": "Отметката е премахната",
|
"ToastBookmarkRemoveSuccess": "Отметката е премахната",
|
||||||
"ToastBookmarkUpdateSuccess": "Отметката е обновена",
|
|
||||||
"ToastChaptersHaveErrors": "Главите имат грешки",
|
"ToastChaptersHaveErrors": "Главите имат грешки",
|
||||||
"ToastChaptersMustHaveTitles": "Главите трябва да имат заглавия",
|
"ToastChaptersMustHaveTitles": "Главите трябва да имат заглавия",
|
||||||
"ToastCollectionRemoveSuccess": "Колекцията е премахната",
|
"ToastCollectionRemoveSuccess": "Колекцията е премахната",
|
||||||
|
@ -952,7 +952,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "বুকমার্ক তৈরি করতে ব্যর্থ",
|
"ToastBookmarkCreateFailed": "বুকমার্ক তৈরি করতে ব্যর্থ",
|
||||||
"ToastBookmarkCreateSuccess": "বুকমার্ক যোগ করা হয়েছে",
|
"ToastBookmarkCreateSuccess": "বুকমার্ক যোগ করা হয়েছে",
|
||||||
"ToastBookmarkRemoveSuccess": "বুকমার্ক সরানো হয়েছে",
|
"ToastBookmarkRemoveSuccess": "বুকমার্ক সরানো হয়েছে",
|
||||||
"ToastBookmarkUpdateSuccess": "বুকমার্ক আপডেট করা হয়েছে",
|
|
||||||
"ToastCachePurgeFailed": "ক্যাশে পরিষ্কার করতে ব্যর্থ হয়েছে",
|
"ToastCachePurgeFailed": "ক্যাশে পরিষ্কার করতে ব্যর্থ হয়েছে",
|
||||||
"ToastCachePurgeSuccess": "ক্যাশে সফলভাবে পরিষ্কার করা হয়েছে",
|
"ToastCachePurgeSuccess": "ক্যাশে সফলভাবে পরিষ্কার করা হয়েছে",
|
||||||
"ToastChaptersHaveErrors": "অধ্যায়ে ত্রুটি আছে",
|
"ToastChaptersHaveErrors": "অধ্যায়ে ত্রুটি আছে",
|
||||||
|
@ -88,6 +88,8 @@
|
|||||||
"ButtonSaveTracklist": "Desa Pistes",
|
"ButtonSaveTracklist": "Desa Pistes",
|
||||||
"ButtonScan": "Escaneja",
|
"ButtonScan": "Escaneja",
|
||||||
"ButtonScanLibrary": "Escaneja Biblioteca",
|
"ButtonScanLibrary": "Escaneja Biblioteca",
|
||||||
|
"ButtonScrollLeft": "Mou a l'esquerra",
|
||||||
|
"ButtonScrollRight": "Mou a la dreta",
|
||||||
"ButtonSearch": "Cerca",
|
"ButtonSearch": "Cerca",
|
||||||
"ButtonSelectFolderPath": "Selecciona Ruta de Carpeta",
|
"ButtonSelectFolderPath": "Selecciona Ruta de Carpeta",
|
||||||
"ButtonSeries": "Sèries",
|
"ButtonSeries": "Sèries",
|
||||||
@ -896,7 +898,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Error en crear marcador",
|
"ToastBookmarkCreateFailed": "Error en crear marcador",
|
||||||
"ToastBookmarkCreateSuccess": "Marcador afegit",
|
"ToastBookmarkCreateSuccess": "Marcador afegit",
|
||||||
"ToastBookmarkRemoveSuccess": "Marcador eliminat",
|
"ToastBookmarkRemoveSuccess": "Marcador eliminat",
|
||||||
"ToastBookmarkUpdateSuccess": "Marcador actualitzat",
|
|
||||||
"ToastCachePurgeFailed": "Error en purgar la memòria cau",
|
"ToastCachePurgeFailed": "Error en purgar la memòria cau",
|
||||||
"ToastCachePurgeSuccess": "Memòria cau purgada amb èxit",
|
"ToastCachePurgeSuccess": "Memòria cau purgada amb èxit",
|
||||||
"ToastChaptersHaveErrors": "Els capítols tenen errors",
|
"ToastChaptersHaveErrors": "Els capítols tenen errors",
|
||||||
|
@ -572,7 +572,7 @@
|
|||||||
"LabelSettingsLibraryMarkAsFinishedWhen": "Označit položku médií jako dokončenou, když",
|
"LabelSettingsLibraryMarkAsFinishedWhen": "Označit položku médií jako dokončenou, když",
|
||||||
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Přeskočit předchozí knihy v pokračování série",
|
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Přeskočit předchozí knihy v pokračování série",
|
||||||
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "Polička Pokračovat v sérii na domovské stránce zobrazuje první nezačatou knihu v sériích, které mají alespoň jednu knihu dokončenou a žádnou rozečtenou. Povolením tohoto nastavení budou série pokračovat od poslední dokončené knihy namísto první nezačaté knihy.",
|
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "Polička Pokračovat v sérii na domovské stránce zobrazuje první nezačatou knihu v sériích, které mají alespoň jednu knihu dokončenou a žádnou rozečtenou. Povolením tohoto nastavení budou série pokračovat od poslední dokončené knihy namísto první nezačaté knihy.",
|
||||||
"LabelSettingsParseSubtitles": "Analzyovat podtitul",
|
"LabelSettingsParseSubtitles": "Analyzovat podtitul",
|
||||||
"LabelSettingsParseSubtitlesHelp": "Rozparsovat podtitul z názvů složek audioknih.<br>Podtiul musí být oddělen znakem \" - \"<br>tj. \"Název knihy - Zde Podtitul\" má podtitul \"Zde podtitul\"",
|
"LabelSettingsParseSubtitlesHelp": "Rozparsovat podtitul z názvů složek audioknih.<br>Podtiul musí být oddělen znakem \" - \"<br>tj. \"Název knihy - Zde Podtitul\" má podtitul \"Zde podtitul\"",
|
||||||
"LabelSettingsPreferMatchedMetadata": "Preferovat spárovaná metadata",
|
"LabelSettingsPreferMatchedMetadata": "Preferovat spárovaná metadata",
|
||||||
"LabelSettingsPreferMatchedMetadataHelp": "Spárovaná data budou mít při použití funkce Rychlé párování přednost před údaji o položce. Ve výchozím nastavení funkce Rychlé párování pouze doplní chybějící údaje.",
|
"LabelSettingsPreferMatchedMetadataHelp": "Spárovaná data budou mít při použití funkce Rychlé párování přednost před údaji o položce. Ve výchozím nastavení funkce Rychlé párování pouze doplní chybějící údaje.",
|
||||||
@ -756,6 +756,7 @@
|
|||||||
"MessageConfirmResetProgress": "Opravdu chcete zahodit svůj pokrok?",
|
"MessageConfirmResetProgress": "Opravdu chcete zahodit svůj pokrok?",
|
||||||
"MessageConfirmSendEbookToDevice": "Opravdu chcete odeslat e-knihu {0} {1}\" do zařízení \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "Opravdu chcete odeslat e-knihu {0} {1}\" do zařízení \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "Opravdu chcete odpojit tohoto uživatele z OpenID?",
|
"MessageConfirmUnlinkOpenId": "Opravdu chcete odpojit tohoto uživatele z OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} poslechových dní v minulém roce",
|
||||||
"MessageDownloadingEpisode": "Stahuji epizodu",
|
"MessageDownloadingEpisode": "Stahuji epizodu",
|
||||||
"MessageDragFilesIntoTrackOrder": "Přetáhněte soubory do správného pořadí stop",
|
"MessageDragFilesIntoTrackOrder": "Přetáhněte soubory do správného pořadí stop",
|
||||||
"MessageEmbedFailed": "Vložení selhalo!",
|
"MessageEmbedFailed": "Vložení selhalo!",
|
||||||
@ -866,6 +867,8 @@
|
|||||||
"MessageTaskOpmlImportFeedPodcastExists": "Podcast se stejnou cestou již existuje",
|
"MessageTaskOpmlImportFeedPodcastExists": "Podcast se stejnou cestou již existuje",
|
||||||
"MessageTaskOpmlImportFeedPodcastFailed": "Vytváření podcastu selhalo",
|
"MessageTaskOpmlImportFeedPodcastFailed": "Vytváření podcastu selhalo",
|
||||||
"MessageTaskOpmlImportFinished": "Přidáno {0} podcastů",
|
"MessageTaskOpmlImportFinished": "Přidáno {0} podcastů",
|
||||||
|
"MessageTaskOpmlParseFailed": "Selhalo parsování OPML souboru",
|
||||||
|
"MessageTaskOpmlParseFastFail": "Neplatný OPML soubor <opml> tag nenalezen NEBO <outline> tag nenalezen",
|
||||||
"MessageTaskScanItemsAdded": "{0} přidáno",
|
"MessageTaskScanItemsAdded": "{0} přidáno",
|
||||||
"MessageTaskScanItemsMissing": "{0} chybí",
|
"MessageTaskScanItemsMissing": "{0} chybí",
|
||||||
"MessageTaskScanItemsUpdated": "{0} aktualizováno",
|
"MessageTaskScanItemsUpdated": "{0} aktualizováno",
|
||||||
@ -890,6 +893,10 @@
|
|||||||
"NoteUploaderFoldersWithMediaFiles": "Se složkami s multimediálními soubory bude zacházeno jako se samostatnými položkami knihovny.",
|
"NoteUploaderFoldersWithMediaFiles": "Se složkami s multimediálními soubory bude zacházeno jako se samostatnými položkami knihovny.",
|
||||||
"NoteUploaderOnlyAudioFiles": "Pokud nahráváte pouze zvukové soubory, bude s každým zvukovým souborem zacházeno jako se samostatnou audioknihou.",
|
"NoteUploaderOnlyAudioFiles": "Pokud nahráváte pouze zvukové soubory, bude s každým zvukovým souborem zacházeno jako se samostatnou audioknihou.",
|
||||||
"NoteUploaderUnsupportedFiles": "Nepodporované soubory jsou ignorovány. Při výběru nebo přetažení složky jsou ostatní soubory, které nejsou ve složce položek, ignorovány.",
|
"NoteUploaderUnsupportedFiles": "Nepodporované soubory jsou ignorovány. Při výběru nebo přetažení složky jsou ostatní soubory, které nejsou ve složce položek, ignorovány.",
|
||||||
|
"NotificationOnBackupCompletedDescription": "Spuštěno po dokončení zálohování",
|
||||||
|
"NotificationOnBackupFailedDescription": "Spuštěno pokud zálohování selže",
|
||||||
|
"NotificationOnEpisodeDownloadedDescription": "Spuštěno při automatickém stažení epizody podcastu",
|
||||||
|
"NotificationOnTestDescription": "Akce pro otestování upozorňovacího systému",
|
||||||
"PlaceholderNewCollection": "Nový název kolekce",
|
"PlaceholderNewCollection": "Nový název kolekce",
|
||||||
"PlaceholderNewFolderPath": "Nová cesta ke složce",
|
"PlaceholderNewFolderPath": "Nová cesta ke složce",
|
||||||
"PlaceholderNewPlaylist": "Nový název seznamu přehrávání",
|
"PlaceholderNewPlaylist": "Nový název seznamu přehrávání",
|
||||||
@ -900,6 +907,7 @@
|
|||||||
"StatsBooksAdditional": "Některé další zahrnují…",
|
"StatsBooksAdditional": "Některé další zahrnují…",
|
||||||
"StatsBooksFinished": "dokončené knihy",
|
"StatsBooksFinished": "dokončené knihy",
|
||||||
"StatsBooksFinishedThisYear": "Některé knihy dokončené tento rok…",
|
"StatsBooksFinishedThisYear": "Některé knihy dokončené tento rok…",
|
||||||
|
"StatsBooksListenedTo": "knih poslechnuto",
|
||||||
"StatsCollectionGrewTo": "Vaše kolekce knih se rozrostla na…",
|
"StatsCollectionGrewTo": "Vaše kolekce knih se rozrostla na…",
|
||||||
"StatsSessions": "sezení",
|
"StatsSessions": "sezení",
|
||||||
"StatsSpentListening": "stráveno posloucháním",
|
"StatsSpentListening": "stráveno posloucháním",
|
||||||
@ -908,10 +916,13 @@
|
|||||||
"StatsTopGenre": "TOP ŽÁNR",
|
"StatsTopGenre": "TOP ŽÁNR",
|
||||||
"StatsTopGenres": "TOP ŽÁNRY",
|
"StatsTopGenres": "TOP ŽÁNRY",
|
||||||
"StatsTopMonth": "TOP MĚSÍC",
|
"StatsTopMonth": "TOP MĚSÍC",
|
||||||
|
"StatsTopNarrator": "NEJLEPŠÍ VYPRAVĚČ",
|
||||||
|
"StatsTopNarrators": "NEJLEPŠÍ VYPRAVĚČI",
|
||||||
"StatsTotalDuration": "S celkovou dobou…",
|
"StatsTotalDuration": "S celkovou dobou…",
|
||||||
"StatsYearInReview": "ROK V PŘEHLEDU",
|
"StatsYearInReview": "ROK V PŘEHLEDU",
|
||||||
"ToastAccountUpdateSuccess": "Účet aktualizován",
|
"ToastAccountUpdateSuccess": "Účet aktualizován",
|
||||||
"ToastAppriseUrlRequired": "Je nutné zadat Apprise URL",
|
"ToastAppriseUrlRequired": "Je nutné zadat Apprise URL",
|
||||||
|
"ToastAsinRequired": "ASIN vyžadován",
|
||||||
"ToastAuthorImageRemoveSuccess": "Obrázek autora odstraněn",
|
"ToastAuthorImageRemoveSuccess": "Obrázek autora odstraněn",
|
||||||
"ToastAuthorNotFound": "Author \"{0}\" nenalezen",
|
"ToastAuthorNotFound": "Author \"{0}\" nenalezen",
|
||||||
"ToastAuthorRemoveSuccess": "Autor odstraněn",
|
"ToastAuthorRemoveSuccess": "Autor odstraněn",
|
||||||
@ -936,7 +947,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Vytvoření záložky se nezdařilo",
|
"ToastBookmarkCreateFailed": "Vytvoření záložky se nezdařilo",
|
||||||
"ToastBookmarkCreateSuccess": "Přidána záložka",
|
"ToastBookmarkCreateSuccess": "Přidána záložka",
|
||||||
"ToastBookmarkRemoveSuccess": "Záložka odstraněna",
|
"ToastBookmarkRemoveSuccess": "Záložka odstraněna",
|
||||||
"ToastBookmarkUpdateSuccess": "Záložka aktualizována",
|
|
||||||
"ToastCachePurgeFailed": "Nepodařilo se vyčistit mezipaměť",
|
"ToastCachePurgeFailed": "Nepodařilo se vyčistit mezipaměť",
|
||||||
"ToastCachePurgeSuccess": "Vyrovnávací paměť úspěšně vyčištěna",
|
"ToastCachePurgeSuccess": "Vyrovnávací paměť úspěšně vyčištěna",
|
||||||
"ToastChaptersHaveErrors": "Kapitoly obsahují chyby",
|
"ToastChaptersHaveErrors": "Kapitoly obsahují chyby",
|
||||||
|
@ -37,6 +37,8 @@
|
|||||||
"ButtonHide": "Skjul",
|
"ButtonHide": "Skjul",
|
||||||
"ButtonHome": "Hjem",
|
"ButtonHome": "Hjem",
|
||||||
"ButtonIssues": "Problemer",
|
"ButtonIssues": "Problemer",
|
||||||
|
"ButtonJumpBackward": "Hop Tilbage",
|
||||||
|
"ButtonJumpForward": "Hop Fremad",
|
||||||
"ButtonLatest": "Seneste",
|
"ButtonLatest": "Seneste",
|
||||||
"ButtonLibrary": "Bibliotek",
|
"ButtonLibrary": "Bibliotek",
|
||||||
"ButtonLogout": "Log ud",
|
"ButtonLogout": "Log ud",
|
||||||
@ -46,20 +48,30 @@
|
|||||||
"ButtonMatchAllAuthors": "Match alle forfattere",
|
"ButtonMatchAllAuthors": "Match alle forfattere",
|
||||||
"ButtonMatchBooks": "Match bøger",
|
"ButtonMatchBooks": "Match bøger",
|
||||||
"ButtonNevermind": "Glem det",
|
"ButtonNevermind": "Glem det",
|
||||||
|
"ButtonNext": "Næste",
|
||||||
|
"ButtonNextChapter": "Næste Kapitel",
|
||||||
|
"ButtonNextItemInQueue": "Næste Element i Køen",
|
||||||
"ButtonOk": "OK",
|
"ButtonOk": "OK",
|
||||||
"ButtonOpenFeed": "Åbn feed",
|
"ButtonOpenFeed": "Åbn feed",
|
||||||
"ButtonOpenManager": "Åbn manager",
|
"ButtonOpenManager": "Åbn manager",
|
||||||
"ButtonPause": "Pause",
|
"ButtonPause": "Pause",
|
||||||
"ButtonPlay": "Afspil",
|
"ButtonPlay": "Afspil",
|
||||||
|
"ButtonPlayAll": "Afspil Alle",
|
||||||
"ButtonPlaying": "Afspiller",
|
"ButtonPlaying": "Afspiller",
|
||||||
"ButtonPlaylists": "Afspilningslister",
|
"ButtonPlaylists": "Afspilningslister",
|
||||||
|
"ButtonPrevious": "Sidste",
|
||||||
|
"ButtonPreviousChapter": "Sidste Kapitel",
|
||||||
|
"ButtonProbeAudioFile": "Undersøg Lydfil",
|
||||||
"ButtonPurgeAllCache": "Ryd al cache",
|
"ButtonPurgeAllCache": "Ryd al cache",
|
||||||
"ButtonPurgeItemsCache": "Ryd elementcache",
|
"ButtonPurgeItemsCache": "Ryd elementcache",
|
||||||
"ButtonQueueAddItem": "Tilføj til kø",
|
"ButtonQueueAddItem": "Tilføj til kø",
|
||||||
"ButtonQueueRemoveItem": "Fjern fra kø",
|
"ButtonQueueRemoveItem": "Fjern fra kø",
|
||||||
|
"ButtonQuickEmbed": "Hurtig Indlejring",
|
||||||
|
"ButtonQuickEmbedMetadata": "Hurtig Indlejring af Metadata",
|
||||||
"ButtonQuickMatch": "Hurtig Match",
|
"ButtonQuickMatch": "Hurtig Match",
|
||||||
"ButtonReScan": "Gen-scan",
|
"ButtonReScan": "Gen-scan",
|
||||||
"ButtonRead": "Læs",
|
"ButtonRead": "Læs",
|
||||||
|
"ButtonRefresh": "Genindlæs",
|
||||||
"ButtonRemove": "Fjern",
|
"ButtonRemove": "Fjern",
|
||||||
"ButtonRemoveAll": "Fjern Alle",
|
"ButtonRemoveAll": "Fjern Alle",
|
||||||
"ButtonRemoveAllLibraryItems": "Fjern Alle Bibliotekselementer",
|
"ButtonRemoveAllLibraryItems": "Fjern Alle Bibliotekselementer",
|
||||||
@ -67,31 +79,46 @@
|
|||||||
"ButtonRemoveFromContinueReading": "Fjern fra Fortsæt Læsning",
|
"ButtonRemoveFromContinueReading": "Fjern fra Fortsæt Læsning",
|
||||||
"ButtonRemoveSeriesFromContinueSeries": "Fjern Serie fra Fortsæt Serie",
|
"ButtonRemoveSeriesFromContinueSeries": "Fjern Serie fra Fortsæt Serie",
|
||||||
"ButtonReset": "Nulstil",
|
"ButtonReset": "Nulstil",
|
||||||
|
"ButtonResetToDefault": "Nulstil til standard",
|
||||||
"ButtonRestore": "Gendan",
|
"ButtonRestore": "Gendan",
|
||||||
"ButtonSave": "Gem",
|
"ButtonSave": "Gem",
|
||||||
"ButtonSaveAndClose": "Gem & Luk",
|
"ButtonSaveAndClose": "Gem & Luk",
|
||||||
"ButtonSaveTracklist": "Gem Sporliste",
|
"ButtonSaveTracklist": "Gem Sporliste",
|
||||||
|
"ButtonScan": "Scan",
|
||||||
"ButtonScanLibrary": "Scan Bibliotek",
|
"ButtonScanLibrary": "Scan Bibliotek",
|
||||||
|
"ButtonScrollLeft": "Rul til Venstre",
|
||||||
|
"ButtonScrollRight": "Rul til Højre",
|
||||||
"ButtonSearch": "Søg",
|
"ButtonSearch": "Søg",
|
||||||
"ButtonSelectFolderPath": "Vælg Mappen Sti",
|
"ButtonSelectFolderPath": "Vælg Mappen Sti",
|
||||||
"ButtonSeries": "Serier",
|
"ButtonSeries": "Serier",
|
||||||
"ButtonSetChaptersFromTracks": "Sæt kapitler fra spor",
|
"ButtonSetChaptersFromTracks": "Sæt kapitler fra spor",
|
||||||
|
"ButtonShare": "Del",
|
||||||
"ButtonShiftTimes": "Skift Tider",
|
"ButtonShiftTimes": "Skift Tider",
|
||||||
"ButtonShow": "Vis",
|
"ButtonShow": "Vis",
|
||||||
"ButtonStartM4BEncode": "Start M4B Kode",
|
"ButtonStartM4BEncode": "Start M4B Kode",
|
||||||
"ButtonStartMetadataEmbed": "Start Metadata Indlejring",
|
"ButtonStartMetadataEmbed": "Start Metadata Indlejring",
|
||||||
|
"ButtonStats": "Statistik",
|
||||||
"ButtonSubmit": "Send",
|
"ButtonSubmit": "Send",
|
||||||
|
"ButtonTest": "Test",
|
||||||
|
"ButtonUnlinkOpenId": "Afkobl OpenID",
|
||||||
|
"ButtonUpload": "Upload",
|
||||||
|
"ButtonUploadBackup": "Upload Backup",
|
||||||
"ButtonUploadCover": "Upload Omslag",
|
"ButtonUploadCover": "Upload Omslag",
|
||||||
"ButtonUploadOPMLFile": "Upload OPML Fil",
|
"ButtonUploadOPMLFile": "Upload OPML Fil",
|
||||||
"ButtonUserDelete": "Slet bruger {0}",
|
"ButtonUserDelete": "Slet bruger {0}",
|
||||||
"ButtonUserEdit": "Rediger bruger {0}",
|
"ButtonUserEdit": "Rediger bruger {0}",
|
||||||
"ButtonViewAll": "Vis Alle",
|
"ButtonViewAll": "Vis Alle",
|
||||||
"ButtonYes": "Ja",
|
"ButtonYes": "Ja",
|
||||||
|
"ErrorUploadFetchMetadataAPI": "Fejl henter metadata",
|
||||||
|
"ErrorUploadFetchMetadataNoResults": "Kunne ikke hente metadata - prøv at uploade title og/eller forfatter",
|
||||||
|
"ErrorUploadLacksTitle": "Skal have en title",
|
||||||
"HeaderAccount": "Konto",
|
"HeaderAccount": "Konto",
|
||||||
|
"HeaderAddCustomMetadataProvider": "Tilføj Brugerdefineret Metadataudbyder",
|
||||||
"HeaderAdvanced": "Avanceret",
|
"HeaderAdvanced": "Avanceret",
|
||||||
"HeaderAppriseNotificationSettings": "Apprise Notifikationsindstillinger",
|
"HeaderAppriseNotificationSettings": "Apprise Notifikationsindstillinger",
|
||||||
"HeaderAudioTracks": "Lydspor",
|
"HeaderAudioTracks": "Lydspor",
|
||||||
"HeaderAudiobookTools": "Audiobog Filhåndteringsværktøjer",
|
"HeaderAudiobookTools": "Audiobog Filhåndteringsværktøjer",
|
||||||
|
"HeaderAuthentication": "Autentificering",
|
||||||
"HeaderBackups": "Sikkerhedskopier",
|
"HeaderBackups": "Sikkerhedskopier",
|
||||||
"HeaderChangePassword": "Skift Adgangskode",
|
"HeaderChangePassword": "Skift Adgangskode",
|
||||||
"HeaderChapters": "Kapitler",
|
"HeaderChapters": "Kapitler",
|
||||||
@ -100,9 +127,12 @@
|
|||||||
"HeaderCollectionItems": "Samlingselementer",
|
"HeaderCollectionItems": "Samlingselementer",
|
||||||
"HeaderCover": "Omslag",
|
"HeaderCover": "Omslag",
|
||||||
"HeaderCurrentDownloads": "Nuværende Downloads",
|
"HeaderCurrentDownloads": "Nuværende Downloads",
|
||||||
|
"HeaderCustomMessageOnLogin": "Brugerdefineret Besked ved Login",
|
||||||
|
"HeaderCustomMetadataProviders": "Brugerdefineret Metadataudbyder",
|
||||||
"HeaderDetails": "Detaljer",
|
"HeaderDetails": "Detaljer",
|
||||||
"HeaderDownloadQueue": "Download Kø",
|
"HeaderDownloadQueue": "Download Kø",
|
||||||
"HeaderEbookFiles": "E-bogsfiler",
|
"HeaderEbookFiles": "E-bogsfiler",
|
||||||
|
"HeaderEmail": "Email",
|
||||||
"HeaderEmailSettings": "Email Indstillinger",
|
"HeaderEmailSettings": "Email Indstillinger",
|
||||||
"HeaderEpisodes": "Episoder",
|
"HeaderEpisodes": "Episoder",
|
||||||
"HeaderEreaderDevices": "E-læser Enheder",
|
"HeaderEreaderDevices": "E-læser Enheder",
|
||||||
@ -120,33 +150,47 @@
|
|||||||
"HeaderListeningSessions": "Lyttesessioner",
|
"HeaderListeningSessions": "Lyttesessioner",
|
||||||
"HeaderListeningStats": "Lyttestatistik",
|
"HeaderListeningStats": "Lyttestatistik",
|
||||||
"HeaderLogin": "Log ind",
|
"HeaderLogin": "Log ind",
|
||||||
|
"HeaderLogs": "Logs",
|
||||||
"HeaderManageGenres": "Administrer Genrer",
|
"HeaderManageGenres": "Administrer Genrer",
|
||||||
"HeaderManageTags": "Administrer Tags",
|
"HeaderManageTags": "Administrer Tags",
|
||||||
"HeaderMapDetails": "Kort Detaljer",
|
"HeaderMapDetails": "Kort Detaljer",
|
||||||
|
"HeaderMatch": "Match",
|
||||||
|
"HeaderMetadataOrderOfPrecedence": "Metadata-prioritet",
|
||||||
"HeaderMetadataToEmbed": "Metadata til indlejring",
|
"HeaderMetadataToEmbed": "Metadata til indlejring",
|
||||||
"HeaderNewAccount": "Ny Konto",
|
"HeaderNewAccount": "Ny Konto",
|
||||||
"HeaderNewLibrary": "Nyt Bibliotek",
|
"HeaderNewLibrary": "Nyt Bibliotek",
|
||||||
|
"HeaderNotificationCreate": "Opret Notifikation",
|
||||||
|
"HeaderNotificationUpdate": "Updater Notifikation",
|
||||||
"HeaderNotifications": "Meddelelser",
|
"HeaderNotifications": "Meddelelser",
|
||||||
|
"HeaderOpenIDConnectAuthentication": "OpenID Connect-autentificering",
|
||||||
|
"HeaderOpenListeningSessions": "Åbne lyttesessioner",
|
||||||
"HeaderOpenRSSFeed": "Åbn RSS Feed",
|
"HeaderOpenRSSFeed": "Åbn RSS Feed",
|
||||||
"HeaderOtherFiles": "Andre Filer",
|
"HeaderOtherFiles": "Andre Filer",
|
||||||
|
"HeaderPasswordAuthentication": "Adgangskodeautentificering",
|
||||||
"HeaderPermissions": "Tilladelser",
|
"HeaderPermissions": "Tilladelser",
|
||||||
"HeaderPlayerQueue": "Afspilningskø",
|
"HeaderPlayerQueue": "Afspilningskø",
|
||||||
|
"HeaderPlayerSettings": "Afspiller Indstillinger",
|
||||||
"HeaderPlaylist": "Afspilningsliste",
|
"HeaderPlaylist": "Afspilningsliste",
|
||||||
"HeaderPlaylistItems": "Afspilningsliste Elementer",
|
"HeaderPlaylistItems": "Afspilningsliste Elementer",
|
||||||
"HeaderPodcastsToAdd": "Podcasts til Tilføjelse",
|
"HeaderPodcastsToAdd": "Podcasts til Tilføjelse",
|
||||||
"HeaderPreviewCover": "Forhåndsvis Omslag",
|
"HeaderPreviewCover": "Forhåndsvis Omslag",
|
||||||
"HeaderRSSFeedGeneral": "RSS Detaljer",
|
"HeaderRSSFeedGeneral": "RSS Detaljer",
|
||||||
"HeaderRSSFeedIsOpen": "RSS Feed er Åben",
|
"HeaderRSSFeedIsOpen": "RSS Feed er Åben",
|
||||||
|
"HeaderRSSFeeds": "RSS-Feeds",
|
||||||
"HeaderRemoveEpisode": "Fjern Episode",
|
"HeaderRemoveEpisode": "Fjern Episode",
|
||||||
"HeaderRemoveEpisodes": "Fjern {0} Episoder",
|
"HeaderRemoveEpisodes": "Fjern {0} Episoder",
|
||||||
"HeaderSavedMediaProgress": "Gemt Medieforløb",
|
"HeaderSavedMediaProgress": "Gemt Medieforløb",
|
||||||
"HeaderSchedule": "Planlæg",
|
"HeaderSchedule": "Planlæg",
|
||||||
|
"HeaderScheduleEpisodeDownloads": "Planlæg Automatisk Episode-Download",
|
||||||
"HeaderScheduleLibraryScans": "Planlæg Automatiske Biblioteksscanninger",
|
"HeaderScheduleLibraryScans": "Planlæg Automatiske Biblioteksscanninger",
|
||||||
|
"HeaderSession": "Session",
|
||||||
"HeaderSetBackupSchedule": "Indstil Sikkerhedskopieringsplan",
|
"HeaderSetBackupSchedule": "Indstil Sikkerhedskopieringsplan",
|
||||||
"HeaderSettings": "Indstillinger",
|
"HeaderSettings": "Indstillinger",
|
||||||
"HeaderSettingsDisplay": "Skærm",
|
"HeaderSettingsDisplay": "Skærm",
|
||||||
"HeaderSettingsExperimental": "Eksperimentelle Funktioner",
|
"HeaderSettingsExperimental": "Eksperimentelle Funktioner",
|
||||||
"HeaderSettingsGeneral": "Generelt",
|
"HeaderSettingsGeneral": "Generelt",
|
||||||
|
"HeaderSettingsScanner": "Scanner",
|
||||||
|
"HeaderSettingsWebClient": "Webklient",
|
||||||
"HeaderSleepTimer": "Søvntimer",
|
"HeaderSleepTimer": "Søvntimer",
|
||||||
"HeaderStatsLargestItems": "Største Elementer",
|
"HeaderStatsLargestItems": "Største Elementer",
|
||||||
"HeaderStatsLongestItems": "Længste Elementer (timer)",
|
"HeaderStatsLongestItems": "Længste Elementer (timer)",
|
||||||
@ -161,7 +205,12 @@
|
|||||||
"HeaderUpdateDetails": "Opdater Detaljer",
|
"HeaderUpdateDetails": "Opdater Detaljer",
|
||||||
"HeaderUpdateLibrary": "Opdater Bibliotek",
|
"HeaderUpdateLibrary": "Opdater Bibliotek",
|
||||||
"HeaderUsers": "Brugere",
|
"HeaderUsers": "Brugere",
|
||||||
|
"HeaderYearReview": "Gennemgang af År {0}",
|
||||||
"HeaderYourStats": "Dine Statistikker",
|
"HeaderYourStats": "Dine Statistikker",
|
||||||
|
"LabelAbridged": "Forkortet",
|
||||||
|
"LabelAbridgedChecked": "Forkortet (kontrolleret)",
|
||||||
|
"LabelAbridgedUnchecked": "Uforkortet (ikke kontrolleret)",
|
||||||
|
"LabelAccessibleBy": "Tilgængelig af",
|
||||||
"LabelAccountType": "Kontotype",
|
"LabelAccountType": "Kontotype",
|
||||||
"LabelAccountTypeAdmin": "Administrator",
|
"LabelAccountTypeAdmin": "Administrator",
|
||||||
"LabelAccountTypeGuest": "Gæst",
|
"LabelAccountTypeGuest": "Gæst",
|
||||||
@ -172,15 +221,26 @@
|
|||||||
"LabelAddToPlaylist": "Tilføj til Afspilningsliste",
|
"LabelAddToPlaylist": "Tilføj til Afspilningsliste",
|
||||||
"LabelAddToPlaylistBatch": "Tilføj {0} Elementer til Afspilningsliste",
|
"LabelAddToPlaylistBatch": "Tilføj {0} Elementer til Afspilningsliste",
|
||||||
"LabelAddedAt": "Tilføjet Kl.",
|
"LabelAddedAt": "Tilføjet Kl.",
|
||||||
|
"LabelAdminUsersOnly": "Kun Administratorbrugere",
|
||||||
"LabelAll": "Alle",
|
"LabelAll": "Alle",
|
||||||
"LabelAllUsers": "Alle Brugere",
|
"LabelAllUsers": "Alle Brugere",
|
||||||
|
"LabelAllUsersExcludingGuests": "Alle bruger eksklusiv gæster",
|
||||||
|
"LabelAllUsersIncludingGuests": "Alle bruger inklusiv gæster",
|
||||||
"LabelAlreadyInYourLibrary": "Allerede i dit bibliotek",
|
"LabelAlreadyInYourLibrary": "Allerede i dit bibliotek",
|
||||||
|
"LabelApiToken": "API Token",
|
||||||
"LabelAppend": "Tilføj",
|
"LabelAppend": "Tilføj",
|
||||||
|
"LabelAudioBitrate": "Lydbitrate (f.eks. 128k)",
|
||||||
|
"LabelAudioChannels": "Lydkanaler (1 eller 2)",
|
||||||
|
"LabelAudioCodec": "Lydkodek",
|
||||||
"LabelAuthor": "Forfatter",
|
"LabelAuthor": "Forfatter",
|
||||||
"LabelAuthorFirstLast": "Forfatter (Fornavn Efternavn)",
|
"LabelAuthorFirstLast": "Forfatter (Fornavn Efternavn)",
|
||||||
"LabelAuthorLastFirst": "Forfatter (Efternavn, Fornavn)",
|
"LabelAuthorLastFirst": "Forfatter (Efternavn, Fornavn)",
|
||||||
"LabelAuthors": "Forfattere",
|
"LabelAuthors": "Forfattere",
|
||||||
"LabelAutoDownloadEpisodes": "Auto Download Episoder",
|
"LabelAutoDownloadEpisodes": "Auto Download Episoder",
|
||||||
|
"LabelAutoFetchMetadata": "Automatisk Hent Metadata",
|
||||||
|
"LabelAutoFetchMetadataHelp": "Henter metadata for titler, forfatter og serier for at strømligne uploading. Ekstra metadata har måske brug for at blive matchet efter upload.",
|
||||||
|
"LabelAutoLaunch": "Åben Automatisk",
|
||||||
|
"LabelAutoLaunchDescription": "Viderestil automatisk til login-udbyderen ved navigation til login-siden (manuel overstyring via <code>/login?autoLaunch=0</code>)",
|
||||||
"LabelBackToUser": "Tilbage til Bruger",
|
"LabelBackToUser": "Tilbage til Bruger",
|
||||||
"LabelBackupLocation": "Backup Placering",
|
"LabelBackupLocation": "Backup Placering",
|
||||||
"LabelBackupsEnableAutomaticBackups": "Aktivér automatisk sikkerhedskopiering",
|
"LabelBackupsEnableAutomaticBackups": "Aktivér automatisk sikkerhedskopiering",
|
||||||
@ -190,6 +250,7 @@
|
|||||||
"LabelBackupsNumberToKeep": "Antal sikkerhedskopier at beholde",
|
"LabelBackupsNumberToKeep": "Antal sikkerhedskopier at beholde",
|
||||||
"LabelBackupsNumberToKeepHelp": "Kun 1 sikkerhedskopi fjernes ad gangen, så hvis du allerede har flere sikkerhedskopier end dette, skal du fjerne dem manuelt.",
|
"LabelBackupsNumberToKeepHelp": "Kun 1 sikkerhedskopi fjernes ad gangen, så hvis du allerede har flere sikkerhedskopier end dette, skal du fjerne dem manuelt.",
|
||||||
"LabelBooks": "Bøger",
|
"LabelBooks": "Bøger",
|
||||||
|
"LabelByAuthor": "af {0}",
|
||||||
"LabelChangePassword": "Ændre Adgangskode",
|
"LabelChangePassword": "Ændre Adgangskode",
|
||||||
"LabelChannels": "Kanaler",
|
"LabelChannels": "Kanaler",
|
||||||
"LabelChapterTitle": "Kapitel Titel",
|
"LabelChapterTitle": "Kapitel Titel",
|
||||||
@ -636,7 +697,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Mislykkedes oprettelse af bogmærke",
|
"ToastBookmarkCreateFailed": "Mislykkedes oprettelse af bogmærke",
|
||||||
"ToastBookmarkCreateSuccess": "Bogmærke tilføjet",
|
"ToastBookmarkCreateSuccess": "Bogmærke tilføjet",
|
||||||
"ToastBookmarkRemoveSuccess": "Bogmærke fjernet",
|
"ToastBookmarkRemoveSuccess": "Bogmærke fjernet",
|
||||||
"ToastBookmarkUpdateSuccess": "Bogmærke opdateret",
|
|
||||||
"ToastChaptersHaveErrors": "Kapitler har fejl",
|
"ToastChaptersHaveErrors": "Kapitler har fejl",
|
||||||
"ToastChaptersMustHaveTitles": "Kapitler skal have titler",
|
"ToastChaptersMustHaveTitles": "Kapitler skal have titler",
|
||||||
"ToastCollectionRemoveSuccess": "Samling fjernet",
|
"ToastCollectionRemoveSuccess": "Samling fjernet",
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
"ButtonNext": "Vor",
|
"ButtonNext": "Vor",
|
||||||
"ButtonNextChapter": "Nächstes Kapitel",
|
"ButtonNextChapter": "Nächstes Kapitel",
|
||||||
"ButtonNextItemInQueue": "Das nächste Element in der Warteschlange",
|
"ButtonNextItemInQueue": "Das nächste Element in der Warteschlange",
|
||||||
"ButtonOk": "OK",
|
"ButtonOk": "Einverstanden",
|
||||||
"ButtonOpenFeed": "Feed öffnen",
|
"ButtonOpenFeed": "Feed öffnen",
|
||||||
"ButtonOpenManager": "Manager öffnen",
|
"ButtonOpenManager": "Manager öffnen",
|
||||||
"ButtonPause": "Pausieren",
|
"ButtonPause": "Pausieren",
|
||||||
@ -300,6 +300,7 @@
|
|||||||
"LabelDiscover": "Entdecken",
|
"LabelDiscover": "Entdecken",
|
||||||
"LabelDownload": "Herunterladen",
|
"LabelDownload": "Herunterladen",
|
||||||
"LabelDownloadNEpisodes": "Download {0} Episoden",
|
"LabelDownloadNEpisodes": "Download {0} Episoden",
|
||||||
|
"LabelDownloadable": "Herunterladbar",
|
||||||
"LabelDuration": "Laufzeit",
|
"LabelDuration": "Laufzeit",
|
||||||
"LabelDurationComparisonExactMatch": "(genauer Treffer)",
|
"LabelDurationComparisonExactMatch": "(genauer Treffer)",
|
||||||
"LabelDurationComparisonLonger": "({0} länger)",
|
"LabelDurationComparisonLonger": "({0} länger)",
|
||||||
@ -588,6 +589,7 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "Standardmäßig werden die Metadaten in /metadata/items gespeichert. Wenn diese Option aktiviert ist, werden die Metadaten als OPF-Datei (Textdatei) in dem gleichen Ordner gespeichert in welchem sich auch das Medium befindet",
|
"LabelSettingsStoreMetadataWithItemHelp": "Standardmäßig werden die Metadaten in /metadata/items gespeichert. Wenn diese Option aktiviert ist, werden die Metadaten als OPF-Datei (Textdatei) in dem gleichen Ordner gespeichert in welchem sich auch das Medium befindet",
|
||||||
"LabelSettingsTimeFormat": "Zeitformat",
|
"LabelSettingsTimeFormat": "Zeitformat",
|
||||||
"LabelShare": "Freigeben",
|
"LabelShare": "Freigeben",
|
||||||
|
"LabelShareDownloadableHelp": "Erlaubt es einem Nutzer, mit dem Link, die Dateien des Mediums als ZIP herunterzuladen.",
|
||||||
"LabelShareOpen": "Freigeben",
|
"LabelShareOpen": "Freigeben",
|
||||||
"LabelShareURL": "Freigabe URL",
|
"LabelShareURL": "Freigabe URL",
|
||||||
"LabelShowAll": "Alles anzeigen",
|
"LabelShowAll": "Alles anzeigen",
|
||||||
@ -756,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "Möchtest du Ihren Fortschritt wirklich zurücksetzen?",
|
"MessageConfirmResetProgress": "Möchtest du Ihren Fortschritt wirklich zurücksetzen?",
|
||||||
"MessageConfirmSendEbookToDevice": "{0} E-Buch „{1}“ wird auf das Gerät „{2}“ gesendet! Bist du dir sicher?",
|
"MessageConfirmSendEbookToDevice": "{0} E-Buch „{1}“ wird auf das Gerät „{2}“ gesendet! Bist du dir sicher?",
|
||||||
"MessageConfirmUnlinkOpenId": "Möchtest du die Verknüpfung dieses Benutzers mit OpenID wirklich löschen?",
|
"MessageConfirmUnlinkOpenId": "Möchtest du die Verknüpfung dieses Benutzers mit OpenID wirklich löschen?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} Tage in dem letzten Jahr gehört",
|
||||||
"MessageDownloadingEpisode": "Episode wird heruntergeladen",
|
"MessageDownloadingEpisode": "Episode wird heruntergeladen",
|
||||||
"MessageDragFilesIntoTrackOrder": "Verschiebe die Dateien in die richtige Reihenfolge",
|
"MessageDragFilesIntoTrackOrder": "Verschiebe die Dateien in die richtige Reihenfolge",
|
||||||
"MessageEmbedFailed": "Einbetten fehlgeschlagen!",
|
"MessageEmbedFailed": "Einbetten fehlgeschlagen!",
|
||||||
@ -834,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "Kapitel und vorgenommenen Änderungen werden zurückgesetzt und rückgängig gemacht! Bist du dir sicher?",
|
"MessageResetChaptersConfirm": "Kapitel und vorgenommenen Änderungen werden zurückgesetzt und rückgängig gemacht! Bist du dir sicher?",
|
||||||
"MessageRestoreBackupConfirm": "Bist du dir sicher, dass du die Sicherung wiederherstellen willst, welche am",
|
"MessageRestoreBackupConfirm": "Bist du dir sicher, dass du die Sicherung wiederherstellen willst, welche am",
|
||||||
"MessageRestoreBackupWarning": "Bei der Wiederherstellung einer Sicherung wird die gesamte Datenbank unter /config und die Titelbilder in /metadata/items und /metadata/authors überschrieben.<br /><br />Bei der Sicherung werden keine Dateien in deinen Bibliotheksordnern verändert. Wenn du die Servereinstellungen aktiviert hast, um Cover und Metadaten in deinen Bibliotheksordnern zu speichern, werden diese nicht gesichert oder überschrieben.<br /><br />Alle Clients, die Ihren Server nutzen, werden automatisch aktualisiert.",
|
"MessageRestoreBackupWarning": "Bei der Wiederherstellung einer Sicherung wird die gesamte Datenbank unter /config und die Titelbilder in /metadata/items und /metadata/authors überschrieben.<br /><br />Bei der Sicherung werden keine Dateien in deinen Bibliotheksordnern verändert. Wenn du die Servereinstellungen aktiviert hast, um Cover und Metadaten in deinen Bibliotheksordnern zu speichern, werden diese nicht gesichert oder überschrieben.<br /><br />Alle Clients, die Ihren Server nutzen, werden automatisch aktualisiert.",
|
||||||
|
"MessageScheduleLibraryScanNote": "Für die meisten Nutzer wird empfohlen, diese Funktion deaktiviert zu lassen und stattdessen die Ordnerüberwachung aktiviert zu lassen. Die Ordnerüberwachung erkennt automatisch Änderungen in deinen Bibliotheksordnern. Da die Ordnerüberwachung jedoch nicht mit jedem Dateisystem (z.B. NFS) funktioniert, können alternativ hier geplante Bibliotheks-Scans aktiviert werden.",
|
||||||
"MessageSearchResultsFor": "Suchergebnisse für",
|
"MessageSearchResultsFor": "Suchergebnisse für",
|
||||||
"MessageSelected": "{0} ausgewählt",
|
"MessageSelected": "{0} ausgewählt",
|
||||||
"MessageServerCouldNotBeReached": "Server kann nicht erreicht werden",
|
"MessageServerCouldNotBeReached": "Server kann nicht erreicht werden",
|
||||||
@ -909,7 +913,7 @@
|
|||||||
"StatsBooksFinished": "Beendete Bücher",
|
"StatsBooksFinished": "Beendete Bücher",
|
||||||
"StatsBooksFinishedThisYear": "Einige Bücher, die dieses Jahr beendet wurden…",
|
"StatsBooksFinishedThisYear": "Einige Bücher, die dieses Jahr beendet wurden…",
|
||||||
"StatsBooksListenedTo": "gehörte Bücher",
|
"StatsBooksListenedTo": "gehörte Bücher",
|
||||||
"StatsCollectionGrewTo": "Deine Bückersammlung ist gewachsen auf…",
|
"StatsCollectionGrewTo": "Deine Büchersammlung ist gewachsen auf…",
|
||||||
"StatsSessions": "Sitzungen",
|
"StatsSessions": "Sitzungen",
|
||||||
"StatsSpentListening": "zugehört",
|
"StatsSpentListening": "zugehört",
|
||||||
"StatsTopAuthor": "TOP AUTOR",
|
"StatsTopAuthor": "TOP AUTOR",
|
||||||
@ -950,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Lesezeichen konnte nicht erstellt werden",
|
"ToastBookmarkCreateFailed": "Lesezeichen konnte nicht erstellt werden",
|
||||||
"ToastBookmarkCreateSuccess": "Lesezeichen hinzugefügt",
|
"ToastBookmarkCreateSuccess": "Lesezeichen hinzugefügt",
|
||||||
"ToastBookmarkRemoveSuccess": "Lesezeichen entfernt",
|
"ToastBookmarkRemoveSuccess": "Lesezeichen entfernt",
|
||||||
"ToastBookmarkUpdateSuccess": "Lesezeichen aktualisiert",
|
|
||||||
"ToastCachePurgeFailed": "Cache leeren fehlgeschlagen",
|
"ToastCachePurgeFailed": "Cache leeren fehlgeschlagen",
|
||||||
"ToastCachePurgeSuccess": "Cache geleert",
|
"ToastCachePurgeSuccess": "Cache geleert",
|
||||||
"ToastChaptersHaveErrors": "Kapitel sind fehlerhaft",
|
"ToastChaptersHaveErrors": "Kapitel sind fehlerhaft",
|
||||||
@ -961,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Sammlung entfernt",
|
"ToastCollectionRemoveSuccess": "Sammlung entfernt",
|
||||||
"ToastCollectionUpdateSuccess": "Sammlung aktualisiert",
|
"ToastCollectionUpdateSuccess": "Sammlung aktualisiert",
|
||||||
"ToastCoverUpdateFailed": "Cover-Update fehlgeschlagen",
|
"ToastCoverUpdateFailed": "Cover-Update fehlgeschlagen",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Datum und Zeit ist ungültig oder unvollständig",
|
||||||
"ToastDeleteFileFailed": "Die Datei konnte nicht gelöscht werden",
|
"ToastDeleteFileFailed": "Die Datei konnte nicht gelöscht werden",
|
||||||
"ToastDeleteFileSuccess": "Datei gelöscht",
|
"ToastDeleteFileSuccess": "Datei gelöscht",
|
||||||
"ToastDeviceAddFailed": "Gerät konnte nicht hinzugefügt werden",
|
"ToastDeviceAddFailed": "Gerät konnte nicht hinzugefügt werden",
|
||||||
@ -1013,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Mindestens ein Tag muss ausgewählt sein",
|
"ToastNewUserTagError": "Mindestens ein Tag muss ausgewählt sein",
|
||||||
"ToastNewUserUsernameError": "Nutzername eingeben",
|
"ToastNewUserUsernameError": "Nutzername eingeben",
|
||||||
"ToastNoNewEpisodesFound": "Keine neuen Episoden gefunden",
|
"ToastNoNewEpisodesFound": "Keine neuen Episoden gefunden",
|
||||||
|
"ToastNoRSSFeed": "Podcast hat keinen RSS Feed",
|
||||||
"ToastNoUpdatesNecessary": "Keine Änderungen nötig",
|
"ToastNoUpdatesNecessary": "Keine Änderungen nötig",
|
||||||
"ToastNotificationCreateFailed": "Fehler beim erstellen der Benachrichtig",
|
"ToastNotificationCreateFailed": "Fehler beim erstellen der Benachrichtig",
|
||||||
"ToastNotificationDeleteFailed": "Fehler beim löschen der Benachrichtigung",
|
"ToastNotificationDeleteFailed": "Fehler beim löschen der Benachrichtigung",
|
||||||
|
@ -837,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "Are you sure you want to reset chapters and undo the changes you made?",
|
"MessageResetChaptersConfirm": "Are you sure you want to reset chapters and undo the changes you made?",
|
||||||
"MessageRestoreBackupConfirm": "Are you sure you want to restore the backup created on",
|
"MessageRestoreBackupConfirm": "Are you sure you want to restore the backup created on",
|
||||||
"MessageRestoreBackupWarning": "Restoring a backup will overwrite the entire database located at /config and cover images in /metadata/items & /metadata/authors.<br /><br />Backups do not modify any files in your library folders. If you have enabled server settings to store cover art and metadata in your library folders then those are not backed up or overwritten.<br /><br />All clients using your server will be automatically refreshed.",
|
"MessageRestoreBackupWarning": "Restoring a backup will overwrite the entire database located at /config and cover images in /metadata/items & /metadata/authors.<br /><br />Backups do not modify any files in your library folders. If you have enabled server settings to store cover art and metadata in your library folders then those are not backed up or overwritten.<br /><br />All clients using your server will be automatically refreshed.",
|
||||||
|
"MessageScheduleLibraryScanNote": "For most users, it is recommended to leave this feature disabled and keep the folder watcher setting enabled. The folder watcher will automatically detect changes in your library folders. The folder watcher doesn't work for every file system (like NFS) so scheduled library scans can be used instead.",
|
||||||
"MessageSearchResultsFor": "Search results for",
|
"MessageSearchResultsFor": "Search results for",
|
||||||
"MessageSelected": "{0} selected",
|
"MessageSelected": "{0} selected",
|
||||||
"MessageServerCouldNotBeReached": "Server could not be reached",
|
"MessageServerCouldNotBeReached": "Server could not be reached",
|
||||||
@ -953,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Failed to create bookmark",
|
"ToastBookmarkCreateFailed": "Failed to create bookmark",
|
||||||
"ToastBookmarkCreateSuccess": "Bookmark added",
|
"ToastBookmarkCreateSuccess": "Bookmark added",
|
||||||
"ToastBookmarkRemoveSuccess": "Bookmark removed",
|
"ToastBookmarkRemoveSuccess": "Bookmark removed",
|
||||||
"ToastBookmarkUpdateSuccess": "Bookmark updated",
|
|
||||||
"ToastCachePurgeFailed": "Failed to purge cache",
|
"ToastCachePurgeFailed": "Failed to purge cache",
|
||||||
"ToastCachePurgeSuccess": "Cache purged successfully",
|
"ToastCachePurgeSuccess": "Cache purged successfully",
|
||||||
"ToastChaptersHaveErrors": "Chapters have errors",
|
"ToastChaptersHaveErrors": "Chapters have errors",
|
||||||
@ -964,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Collection removed",
|
"ToastCollectionRemoveSuccess": "Collection removed",
|
||||||
"ToastCollectionUpdateSuccess": "Collection updated",
|
"ToastCollectionUpdateSuccess": "Collection updated",
|
||||||
"ToastCoverUpdateFailed": "Cover update failed",
|
"ToastCoverUpdateFailed": "Cover update failed",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Date and time is invalid or incomplete",
|
||||||
"ToastDeleteFileFailed": "Failed to delete file",
|
"ToastDeleteFileFailed": "Failed to delete file",
|
||||||
"ToastDeleteFileSuccess": "File deleted",
|
"ToastDeleteFileSuccess": "File deleted",
|
||||||
"ToastDeviceAddFailed": "Failed to add device",
|
"ToastDeviceAddFailed": "Failed to add device",
|
||||||
@ -1016,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Must select at least one tag",
|
"ToastNewUserTagError": "Must select at least one tag",
|
||||||
"ToastNewUserUsernameError": "Enter a username",
|
"ToastNewUserUsernameError": "Enter a username",
|
||||||
"ToastNoNewEpisodesFound": "No new episodes found",
|
"ToastNoNewEpisodesFound": "No new episodes found",
|
||||||
|
"ToastNoRSSFeed": "Podcast does not have an RSS Feed",
|
||||||
"ToastNoUpdatesNecessary": "No updates necessary",
|
"ToastNoUpdatesNecessary": "No updates necessary",
|
||||||
"ToastNotificationCreateFailed": "Failed to create notification",
|
"ToastNotificationCreateFailed": "Failed to create notification",
|
||||||
"ToastNotificationDeleteFailed": "Failed to delete notification",
|
"ToastNotificationDeleteFailed": "Failed to delete notification",
|
||||||
|
@ -300,6 +300,7 @@
|
|||||||
"LabelDiscover": "Descubrir",
|
"LabelDiscover": "Descubrir",
|
||||||
"LabelDownload": "Descargar",
|
"LabelDownload": "Descargar",
|
||||||
"LabelDownloadNEpisodes": "Descargar {0} episodios",
|
"LabelDownloadNEpisodes": "Descargar {0} episodios",
|
||||||
|
"LabelDownloadable": "Descarregable",
|
||||||
"LabelDuration": "Duración",
|
"LabelDuration": "Duración",
|
||||||
"LabelDurationComparisonExactMatch": "(coincidencia exacta)",
|
"LabelDurationComparisonExactMatch": "(coincidencia exacta)",
|
||||||
"LabelDurationComparisonLonger": "({0} más largo)",
|
"LabelDurationComparisonLonger": "({0} más largo)",
|
||||||
@ -588,6 +589,7 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "Por defecto, los archivos de metadatos se almacenan en /metadata/items. Si habilita esta opción, los archivos de metadatos se guardarán en la carpeta de elementos de su biblioteca",
|
"LabelSettingsStoreMetadataWithItemHelp": "Por defecto, los archivos de metadatos se almacenan en /metadata/items. Si habilita esta opción, los archivos de metadatos se guardarán en la carpeta de elementos de su biblioteca",
|
||||||
"LabelSettingsTimeFormat": "Formato de Tiempo",
|
"LabelSettingsTimeFormat": "Formato de Tiempo",
|
||||||
"LabelShare": "Compartir",
|
"LabelShare": "Compartir",
|
||||||
|
"LabelShareDownloadableHelp": "Permet als usuaris amb l'enllaç compartit descarregar un arxiu zip amb l'item de la llibreria.",
|
||||||
"LabelShareOpen": "abrir un recurso compartido",
|
"LabelShareOpen": "abrir un recurso compartido",
|
||||||
"LabelShareURL": "Compartir la URL",
|
"LabelShareURL": "Compartir la URL",
|
||||||
"LabelShowAll": "Mostrar Todos",
|
"LabelShowAll": "Mostrar Todos",
|
||||||
@ -756,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "¿Estás seguro de que quieres reiniciar tu progreso?",
|
"MessageConfirmResetProgress": "¿Estás seguro de que quieres reiniciar tu progreso?",
|
||||||
"MessageConfirmSendEbookToDevice": "¿Está seguro de que enviar {0} ebook(s) \"{1}\" al dispositivo \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "¿Está seguro de que enviar {0} ebook(s) \"{1}\" al dispositivo \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "¿Estás seguro de que deseas desvincular este usuario de OpenID?",
|
"MessageConfirmUnlinkOpenId": "¿Estás seguro de que deseas desvincular este usuario de OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} dies escoltats en l'últim any",
|
||||||
"MessageDownloadingEpisode": "Descargando Capitulo",
|
"MessageDownloadingEpisode": "Descargando Capitulo",
|
||||||
"MessageDragFilesIntoTrackOrder": "Arrastra los archivos al orden correcto de las pistas",
|
"MessageDragFilesIntoTrackOrder": "Arrastra los archivos al orden correcto de las pistas",
|
||||||
"MessageEmbedFailed": "¡Error al insertar!",
|
"MessageEmbedFailed": "¡Error al insertar!",
|
||||||
@ -950,7 +953,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Error al crear marcador",
|
"ToastBookmarkCreateFailed": "Error al crear marcador",
|
||||||
"ToastBookmarkCreateSuccess": "Marcador Agregado",
|
"ToastBookmarkCreateSuccess": "Marcador Agregado",
|
||||||
"ToastBookmarkRemoveSuccess": "Marcador eliminado",
|
"ToastBookmarkRemoveSuccess": "Marcador eliminado",
|
||||||
"ToastBookmarkUpdateSuccess": "Marcador actualizado",
|
|
||||||
"ToastCachePurgeFailed": "Error al purgar el caché",
|
"ToastCachePurgeFailed": "Error al purgar el caché",
|
||||||
"ToastCachePurgeSuccess": "Caché purgado de manera exitosa",
|
"ToastCachePurgeSuccess": "Caché purgado de manera exitosa",
|
||||||
"ToastChaptersHaveErrors": "Los capítulos tienen errores",
|
"ToastChaptersHaveErrors": "Los capítulos tienen errores",
|
||||||
@ -961,6 +963,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Colección removida",
|
"ToastCollectionRemoveSuccess": "Colección removida",
|
||||||
"ToastCollectionUpdateSuccess": "Colección actualizada",
|
"ToastCollectionUpdateSuccess": "Colección actualizada",
|
||||||
"ToastCoverUpdateFailed": "Error al actualizar la cubierta",
|
"ToastCoverUpdateFailed": "Error al actualizar la cubierta",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Fecha y hora inválidas o incompletas",
|
||||||
"ToastDeleteFileFailed": "Error el eliminar archivo",
|
"ToastDeleteFileFailed": "Error el eliminar archivo",
|
||||||
"ToastDeleteFileSuccess": "Archivo eliminado",
|
"ToastDeleteFileSuccess": "Archivo eliminado",
|
||||||
"ToastDeviceAddFailed": "Error al añadir dispositivo",
|
"ToastDeviceAddFailed": "Error al añadir dispositivo",
|
||||||
@ -997,7 +1000,7 @@
|
|||||||
"ToastLibraryScanFailedToStart": "Error al iniciar el escaneo",
|
"ToastLibraryScanFailedToStart": "Error al iniciar el escaneo",
|
||||||
"ToastLibraryScanStarted": "Se inició el escaneo de la biblioteca",
|
"ToastLibraryScanStarted": "Se inició el escaneo de la biblioteca",
|
||||||
"ToastLibraryUpdateSuccess": "Biblioteca \"{0}\" actualizada",
|
"ToastLibraryUpdateSuccess": "Biblioteca \"{0}\" actualizada",
|
||||||
"ToastMatchAllAuthorsFailed": "No coincide con todos los autores",
|
"ToastMatchAllAuthorsFailed": "No se pudo encontrar a todos los autores",
|
||||||
"ToastMetadataFilesRemovedError": "Error al eliminar metadatos de {0} archivo(s)",
|
"ToastMetadataFilesRemovedError": "Error al eliminar metadatos de {0} archivo(s)",
|
||||||
"ToastMetadataFilesRemovedNoneFound": "No hay metadatos.{0} archivo(s) encontrado(s) en la biblioteca",
|
"ToastMetadataFilesRemovedNoneFound": "No hay metadatos.{0} archivo(s) encontrado(s) en la biblioteca",
|
||||||
"ToastMetadataFilesRemovedNoneRemoved": "Sin metadatos.{0} archivo(s) eliminado(s)",
|
"ToastMetadataFilesRemovedNoneRemoved": "Sin metadatos.{0} archivo(s) eliminado(s)",
|
||||||
@ -1013,6 +1016,7 @@
|
|||||||
"ToastNewUserTagError": "Debes seleccionar al menos una etiqueta",
|
"ToastNewUserTagError": "Debes seleccionar al menos una etiqueta",
|
||||||
"ToastNewUserUsernameError": "Introduce un nombre de usuario",
|
"ToastNewUserUsernameError": "Introduce un nombre de usuario",
|
||||||
"ToastNoNewEpisodesFound": "No se encontraron nuevos episodios",
|
"ToastNoNewEpisodesFound": "No se encontraron nuevos episodios",
|
||||||
|
"ToastNoRSSFeed": "El Podcast no tiene una fuente RSS",
|
||||||
"ToastNoUpdatesNecessary": "No es necesario actualizar",
|
"ToastNoUpdatesNecessary": "No es necesario actualizar",
|
||||||
"ToastNotificationCreateFailed": "Error al crear notificación",
|
"ToastNotificationCreateFailed": "Error al crear notificación",
|
||||||
"ToastNotificationDeleteFailed": "Error al borrar la notificación",
|
"ToastNotificationDeleteFailed": "Error al borrar la notificación",
|
||||||
|
@ -709,7 +709,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Järjehoidja loomine ebaõnnestus",
|
"ToastBookmarkCreateFailed": "Järjehoidja loomine ebaõnnestus",
|
||||||
"ToastBookmarkCreateSuccess": "Järjehoidja lisatud",
|
"ToastBookmarkCreateSuccess": "Järjehoidja lisatud",
|
||||||
"ToastBookmarkRemoveSuccess": "Järjehoidja eemaldatud",
|
"ToastBookmarkRemoveSuccess": "Järjehoidja eemaldatud",
|
||||||
"ToastBookmarkUpdateSuccess": "Järjehoidja värskendatud",
|
|
||||||
"ToastChaptersHaveErrors": "Peatükkidel on vigu",
|
"ToastChaptersHaveErrors": "Peatükkidel on vigu",
|
||||||
"ToastChaptersMustHaveTitles": "Peatükkidel peab olema pealkiri",
|
"ToastChaptersMustHaveTitles": "Peatükkidel peab olema pealkiri",
|
||||||
"ToastCollectionRemoveSuccess": "Kogum eemaldatud",
|
"ToastCollectionRemoveSuccess": "Kogum eemaldatud",
|
||||||
|
@ -65,11 +65,13 @@
|
|||||||
"ButtonPurgeItemsCache": "Tyhjennä kohteiden välimuisti",
|
"ButtonPurgeItemsCache": "Tyhjennä kohteiden välimuisti",
|
||||||
"ButtonQueueAddItem": "Lisää jonoon",
|
"ButtonQueueAddItem": "Lisää jonoon",
|
||||||
"ButtonQueueRemoveItem": "Poista jonosta",
|
"ButtonQueueRemoveItem": "Poista jonosta",
|
||||||
|
"ButtonQuickEmbed": "Pikaupota",
|
||||||
|
"ButtonQuickEmbedMetadata": "Upota kuvailutiedot nopeasti",
|
||||||
"ButtonQuickMatch": "Pikatäsmää",
|
"ButtonQuickMatch": "Pikatäsmää",
|
||||||
"ButtonReScan": "Uudelleenskannaa",
|
"ButtonReScan": "Uudelleenskannaa",
|
||||||
"ButtonRead": "Lue",
|
"ButtonRead": "Lue",
|
||||||
"ButtonReadLess": "Näytä vähemmän",
|
"ButtonReadLess": "Lue vähemmän",
|
||||||
"ButtonReadMore": "Näytä enemmän",
|
"ButtonReadMore": "Lue enemmän",
|
||||||
"ButtonRefresh": "Päivitä",
|
"ButtonRefresh": "Päivitä",
|
||||||
"ButtonRemove": "Poista",
|
"ButtonRemove": "Poista",
|
||||||
"ButtonRemoveAll": "Poista kaikki",
|
"ButtonRemoveAll": "Poista kaikki",
|
||||||
@ -85,6 +87,8 @@
|
|||||||
"ButtonSaveTracklist": "Tallenna raitalista",
|
"ButtonSaveTracklist": "Tallenna raitalista",
|
||||||
"ButtonScan": "Skannaa",
|
"ButtonScan": "Skannaa",
|
||||||
"ButtonScanLibrary": "Skannaa kirjasto",
|
"ButtonScanLibrary": "Skannaa kirjasto",
|
||||||
|
"ButtonScrollLeft": "Vieritä vasemmalle",
|
||||||
|
"ButtonScrollRight": "Vieritä oikealle",
|
||||||
"ButtonSearch": "Etsi",
|
"ButtonSearch": "Etsi",
|
||||||
"ButtonSelectFolderPath": "Valitse kansiopolku",
|
"ButtonSelectFolderPath": "Valitse kansiopolku",
|
||||||
"ButtonSeries": "Sarjat",
|
"ButtonSeries": "Sarjat",
|
||||||
@ -148,6 +152,7 @@
|
|||||||
"HeaderLogs": "Lokit",
|
"HeaderLogs": "Lokit",
|
||||||
"HeaderManageGenres": "Hallitse lajityyppejä",
|
"HeaderManageGenres": "Hallitse lajityyppejä",
|
||||||
"HeaderManageTags": "Hallitse tageja",
|
"HeaderManageTags": "Hallitse tageja",
|
||||||
|
"HeaderMetadataOrderOfPrecedence": "Metadatan tärkeysjärjestys",
|
||||||
"HeaderMetadataToEmbed": "Sisällytettävä metadata",
|
"HeaderMetadataToEmbed": "Sisällytettävä metadata",
|
||||||
"HeaderNewAccount": "Uusi tili",
|
"HeaderNewAccount": "Uusi tili",
|
||||||
"HeaderNewLibrary": "Uusi kirjasto",
|
"HeaderNewLibrary": "Uusi kirjasto",
|
||||||
@ -156,6 +161,7 @@
|
|||||||
"HeaderNotifications": "Ilmoitukset",
|
"HeaderNotifications": "Ilmoitukset",
|
||||||
"HeaderOpenRSSFeed": "Avaa RSS-syöte",
|
"HeaderOpenRSSFeed": "Avaa RSS-syöte",
|
||||||
"HeaderOtherFiles": "Muut tiedostot",
|
"HeaderOtherFiles": "Muut tiedostot",
|
||||||
|
"HeaderPasswordAuthentication": "Salasanan todentaminen",
|
||||||
"HeaderPermissions": "Käyttöoikeudet",
|
"HeaderPermissions": "Käyttöoikeudet",
|
||||||
"HeaderPlayerQueue": "Soittimen jono",
|
"HeaderPlayerQueue": "Soittimen jono",
|
||||||
"HeaderPlayerSettings": "Soittimen asetukset",
|
"HeaderPlayerSettings": "Soittimen asetukset",
|
||||||
@ -169,24 +175,34 @@
|
|||||||
"HeaderRemoveEpisode": "Poista jakso",
|
"HeaderRemoveEpisode": "Poista jakso",
|
||||||
"HeaderRemoveEpisodes": "Poista {0} jaksoa",
|
"HeaderRemoveEpisodes": "Poista {0} jaksoa",
|
||||||
"HeaderSchedule": "Ajoita",
|
"HeaderSchedule": "Ajoita",
|
||||||
|
"HeaderScheduleEpisodeDownloads": "Ajoita automaattiset jaksolataukset",
|
||||||
"HeaderScheduleLibraryScans": "Ajoita automaattiset kirjastoskannaukset",
|
"HeaderScheduleLibraryScans": "Ajoita automaattiset kirjastoskannaukset",
|
||||||
"HeaderSession": "Istunto",
|
"HeaderSession": "Istunto",
|
||||||
"HeaderSetBackupSchedule": "Aseta varmuuskopiointiaikataulu",
|
"HeaderSetBackupSchedule": "Aseta varmuuskopiointiaikataulu",
|
||||||
"HeaderSettings": "Asetukset",
|
"HeaderSettings": "Asetukset",
|
||||||
|
"HeaderSettingsDisplay": "Näyttö",
|
||||||
"HeaderSettingsExperimental": "Kokeelliset ominaisuudet",
|
"HeaderSettingsExperimental": "Kokeelliset ominaisuudet",
|
||||||
"HeaderSettingsGeneral": "Yleiset",
|
"HeaderSettingsGeneral": "Yleiset",
|
||||||
|
"HeaderSettingsScanner": "Skannaaja",
|
||||||
"HeaderSleepTimer": "Uniajastin",
|
"HeaderSleepTimer": "Uniajastin",
|
||||||
|
"HeaderStatsLargestItems": "Suurimmat kohteet",
|
||||||
|
"HeaderStatsLongestItems": "Pisimmät kohteet (h)",
|
||||||
"HeaderStatsMinutesListeningChart": "Kuunteluminuutit (viim. 7 pv)",
|
"HeaderStatsMinutesListeningChart": "Kuunteluminuutit (viim. 7 pv)",
|
||||||
"HeaderStatsRecentSessions": "Viimeaikaiset istunnot",
|
"HeaderStatsRecentSessions": "Viimeaikaiset istunnot",
|
||||||
"HeaderStatsTop5Genres": "Top 5 lajityypit",
|
"HeaderStatsTop10Authors": "Suosituimmat 10 kirjailijaa",
|
||||||
|
"HeaderStatsTop5Genres": "Suosituimmat 5 lajityyppiä",
|
||||||
"HeaderTableOfContents": "Sisällysluettelo",
|
"HeaderTableOfContents": "Sisällysluettelo",
|
||||||
"HeaderTools": "Työkalut",
|
"HeaderTools": "Työkalut",
|
||||||
"HeaderUpdateAccount": "Päivitä tili",
|
"HeaderUpdateAccount": "Päivitä tili",
|
||||||
"HeaderUpdateAuthor": "Päivitä kirjailija",
|
"HeaderUpdateAuthor": "Päivitä kirjailija",
|
||||||
|
"HeaderUpdateDetails": "Päivitä yksityiskohdat",
|
||||||
"HeaderUpdateLibrary": "Päivitä kirjasto",
|
"HeaderUpdateLibrary": "Päivitä kirjasto",
|
||||||
"HeaderUsers": "Käyttäjät",
|
"HeaderUsers": "Käyttäjät",
|
||||||
|
"HeaderYearReview": "Vuosi {0} tarkasteltuna",
|
||||||
"HeaderYourStats": "Tilastosi",
|
"HeaderYourStats": "Tilastosi",
|
||||||
"LabelAbridged": "Lyhennetty",
|
"LabelAbridged": "Lyhennetty",
|
||||||
|
"LabelAbridgedChecked": "Lyhennetty (tarkistettu)",
|
||||||
|
"LabelAbridgedUnchecked": "Lyhentämätön (tarkistamaton)",
|
||||||
"LabelAccountType": "Tilin tyyppi",
|
"LabelAccountType": "Tilin tyyppi",
|
||||||
"LabelAccountTypeAdmin": "Järjestelmänvalvoja",
|
"LabelAccountTypeAdmin": "Järjestelmänvalvoja",
|
||||||
"LabelAccountTypeGuest": "Vieras",
|
"LabelAccountTypeGuest": "Vieras",
|
||||||
@ -204,24 +220,40 @@
|
|||||||
"LabelAllUsersExcludingGuests": "Kaikki käyttäjät vieraita lukuun ottamatta",
|
"LabelAllUsersExcludingGuests": "Kaikki käyttäjät vieraita lukuun ottamatta",
|
||||||
"LabelAllUsersIncludingGuests": "Kaikki käyttäjät mukaan lukien vieraat",
|
"LabelAllUsersIncludingGuests": "Kaikki käyttäjät mukaan lukien vieraat",
|
||||||
"LabelAlreadyInYourLibrary": "Jo kirjastossasi",
|
"LabelAlreadyInYourLibrary": "Jo kirjastossasi",
|
||||||
|
"LabelApiToken": "Sovellusliittymätunnus",
|
||||||
|
"LabelAudioBitrate": "Äänen bittinopeus (esim. 128k)",
|
||||||
|
"LabelAudioChannels": "Äänikanavat (1 tai 2)",
|
||||||
|
"LabelAudioCodec": "Äänikoodekki",
|
||||||
"LabelAuthor": "Tekijä",
|
"LabelAuthor": "Tekijä",
|
||||||
"LabelAuthorFirstLast": "Tekijä (Etunimi Sukunimi)",
|
"LabelAuthorFirstLast": "Tekijä (Etunimi Sukunimi)",
|
||||||
"LabelAuthorLastFirst": "Tekijä (Sukunimi, Etunimi)",
|
"LabelAuthorLastFirst": "Tekijä (Sukunimi, Etunimi)",
|
||||||
"LabelAuthors": "Tekijät",
|
"LabelAuthors": "Tekijät",
|
||||||
"LabelAutoDownloadEpisodes": "Lataa jaksot automaattisesti",
|
"LabelAutoDownloadEpisodes": "Lataa jaksot automaattisesti",
|
||||||
|
"LabelAutoFetchMetadata": "Etsi metadata automaattisesti",
|
||||||
|
"LabelAutoLaunch": "Automaattinen käynnistys",
|
||||||
|
"LabelAutoRegister": "Automaattinen rekisteröinti",
|
||||||
|
"LabelAutoRegisterDescription": "Luo automaattisesti uusia käyttäjiä kirjautumisen jälkeen",
|
||||||
"LabelBackToUser": "Takaisin käyttäjään",
|
"LabelBackToUser": "Takaisin käyttäjään",
|
||||||
|
"LabelBackupAudioFiles": "Varmuuskopioi äänitiedostot",
|
||||||
"LabelBackupLocation": "Varmuuskopiointipaikka",
|
"LabelBackupLocation": "Varmuuskopiointipaikka",
|
||||||
"LabelBackupsEnableAutomaticBackups": "Ota automaattinen varmuuskopiointi käyttöön",
|
"LabelBackupsEnableAutomaticBackups": "Ota automaattinen varmuuskopiointi käyttöön",
|
||||||
"LabelBackupsEnableAutomaticBackupsHelp": "Varmuuskopiot tallennettu kansioon /metadata/backups",
|
"LabelBackupsEnableAutomaticBackupsHelp": "Varmuuskopiot tallennettu kansioon /metadata/backups",
|
||||||
"LabelBackupsMaxBackupSize": "Varmuuskopion enimmäiskoko (Gt) (0 rajaton)",
|
"LabelBackupsMaxBackupSize": "Varmuuskopion enimmäiskoko (Gt) (0 rajaton)",
|
||||||
|
"LabelBackupsMaxBackupSizeHelp": "Virheellisten asetusten estämiseksi varmuuskopiot epäonnistuvat, jos ne ovat asetettua kokoa suurempia.",
|
||||||
"LabelBackupsNumberToKeep": "Säilytettävien varmuuskopioiden määrä",
|
"LabelBackupsNumberToKeep": "Säilytettävien varmuuskopioiden määrä",
|
||||||
|
"LabelBackupsNumberToKeepHelp": "Varmuuskopiot poistetaan yksi kerrallaan, joten jos niitä on enemmän kuin yksi, ne on poistettava manuaalisesti.",
|
||||||
"LabelBitrate": "Bittinopeus",
|
"LabelBitrate": "Bittinopeus",
|
||||||
|
"LabelBonus": "Bonus",
|
||||||
"LabelBooks": "Kirjat",
|
"LabelBooks": "Kirjat",
|
||||||
"LabelButtonText": "Painikkeen teksti",
|
"LabelButtonText": "Painikkeen teksti",
|
||||||
"LabelChangePassword": "Vaihda salasana",
|
"LabelChangePassword": "Vaihda salasana",
|
||||||
"LabelChannels": "Kanavat",
|
"LabelChannels": "Kanavat",
|
||||||
|
"LabelChapterCount": "{0} lukua",
|
||||||
|
"LabelChapterTitle": "Luvun nimi",
|
||||||
"LabelChapters": "Luvut",
|
"LabelChapters": "Luvut",
|
||||||
|
"LabelChaptersFound": "lukua löydetty",
|
||||||
"LabelClickForMoreInfo": "Napsauta saadaksesi lisätietoja",
|
"LabelClickForMoreInfo": "Napsauta saadaksesi lisätietoja",
|
||||||
|
"LabelClickToUseCurrentValue": "Käytä nykyistä arvoa napsauttamalla",
|
||||||
"LabelClosePlayer": "Sulje soitin",
|
"LabelClosePlayer": "Sulje soitin",
|
||||||
"LabelCodec": "Koodekki",
|
"LabelCodec": "Koodekki",
|
||||||
"LabelCollapseSeries": "Pienennä sarja",
|
"LabelCollapseSeries": "Pienennä sarja",
|
||||||
@ -236,45 +268,85 @@
|
|||||||
"LabelCoverImageURL": "Kansikuvan URL-osoite",
|
"LabelCoverImageURL": "Kansikuvan URL-osoite",
|
||||||
"LabelCreatedAt": "Luotu",
|
"LabelCreatedAt": "Luotu",
|
||||||
"LabelCurrent": "Nykyinen",
|
"LabelCurrent": "Nykyinen",
|
||||||
|
"LabelCurrently": "Nyt:",
|
||||||
"LabelDays": "Päivää",
|
"LabelDays": "Päivää",
|
||||||
|
"LabelDeleteFromFileSystemCheckbox": "Poista tiedostojärjestelmästä (poista merkintä, jos haluat poistaa vain tietokannasta)",
|
||||||
"LabelDescription": "Kuvaus",
|
"LabelDescription": "Kuvaus",
|
||||||
|
"LabelDeselectAll": "Poista valinta kaikista",
|
||||||
"LabelDevice": "Laite",
|
"LabelDevice": "Laite",
|
||||||
"LabelDeviceInfo": "Laitteen tiedot",
|
"LabelDeviceInfo": "Laitteen tiedot",
|
||||||
|
"LabelDeviceIsAvailableTo": "Laite on saatavilla...",
|
||||||
|
"LabelDirectory": "Kansio",
|
||||||
"LabelDiscover": "Löydä",
|
"LabelDiscover": "Löydä",
|
||||||
"LabelDownload": "Lataa",
|
"LabelDownload": "Lataa",
|
||||||
"LabelDownloadNEpisodes": "Lataa {0} jaksoa",
|
"LabelDownloadNEpisodes": "Lataa {0} jaksoa",
|
||||||
|
"LabelDownloadable": "Ladattavissa",
|
||||||
"LabelDuration": "Kesto",
|
"LabelDuration": "Kesto",
|
||||||
|
"LabelDurationComparisonExactMatch": "(tarkka vastaavuus)",
|
||||||
"LabelDurationComparisonLonger": "({0} pidempi)",
|
"LabelDurationComparisonLonger": "({0} pidempi)",
|
||||||
"LabelDurationComparisonShorter": "({0} lyhyempi)",
|
"LabelDurationComparisonShorter": "({0} lyhyempi)",
|
||||||
|
"LabelDurationFound": "Kesto löydetty:",
|
||||||
"LabelEbook": "E-kirja",
|
"LabelEbook": "E-kirja",
|
||||||
"LabelEbooks": "E-kirjat",
|
"LabelEbooks": "E-kirjat",
|
||||||
"LabelEdit": "Muokkaa",
|
"LabelEdit": "Muokkaa",
|
||||||
"LabelEmail": "Sähköposti",
|
"LabelEmail": "Sähköposti",
|
||||||
|
"LabelEmailSettingsFromAddress": "Osoitteesta",
|
||||||
|
"LabelEmailSettingsRejectUnauthorized": "Hylkää luvattomat sertifikaatit",
|
||||||
|
"LabelEmailSettingsRejectUnauthorizedHelp": "SSL-sertifikaatin varmentamisen käytöstä poistaminen saattaa vaarantaa yhteytesti turvallisuusriskeihin, kuten man-in-the-middle hyökkäyksiin. Poista käytöstä vain jos ymmärrät vaaran ja luotat yhdistämääsi sähköpostipalvelimeen.",
|
||||||
|
"LabelEmailSettingsSecure": "Turvallinen",
|
||||||
"LabelEmailSettingsTestAddress": "Testiosoite",
|
"LabelEmailSettingsTestAddress": "Testiosoite",
|
||||||
"LabelEmbeddedCover": "Upotettu kansikuva",
|
"LabelEmbeddedCover": "Upotettu kansikuva",
|
||||||
"LabelEnable": "Ota käyttöön",
|
"LabelEnable": "Ota käyttöön",
|
||||||
|
"LabelEncodingBackupLocation": "Alkuperäisistä audiotiedostoistasi tallennetaan varmuuskopio osoitteessa:",
|
||||||
|
"LabelEncodingChaptersNotEmbedded": "Lukuja ei upoteta moniraitaisiin äänikirjoihin.",
|
||||||
|
"LabelEncodingInfoEmbedded": "Kuvailutiedot upotetaan äänikirjakansion ääniraitoihin.",
|
||||||
|
"LabelEncodingStartedNavigation": "Voit poistua sivulta kun tehtävä on aloitettu.",
|
||||||
|
"LabelEncodingTimeWarning": "Koodaus saattaa kestää 30 minuuttiin asti.",
|
||||||
|
"LabelEncodingWarningAdvancedSettings": "Varoitus: Älä päivitä näitä asetuksia ellet ymmärrä ffmpeg-koodausasetuksia.",
|
||||||
"LabelEnd": "Loppu",
|
"LabelEnd": "Loppu",
|
||||||
"LabelEndOfChapter": "Luvun loppu",
|
"LabelEndOfChapter": "Luvun loppu",
|
||||||
"LabelEpisode": "Jakso",
|
"LabelEpisode": "Jakso",
|
||||||
|
"LabelEpisodeNotLinkedToRssFeed": "Jakso ei yhdistetty RSS-syötteeseen",
|
||||||
|
"LabelEpisodeNumber": "Jakso #{0}",
|
||||||
|
"LabelEpisodeTitle": "Jakson nimi",
|
||||||
|
"LabelEpisodeType": "Jakson tyyppi",
|
||||||
|
"LabelEpisodeUrlFromRssFeed": "Jakson URL RSS-syötteestä",
|
||||||
"LabelEpisodes": "Jaksot",
|
"LabelEpisodes": "Jaksot",
|
||||||
"LabelExample": "Esimerkki",
|
"LabelExample": "Esimerkki",
|
||||||
|
"LabelExpandSeries": "Laajenna sarja",
|
||||||
|
"LabelExpandSubSeries": "Laajenna alisarja",
|
||||||
|
"LabelExportOPML": "Vie OPML",
|
||||||
"LabelFeedURL": "Syötteen URL",
|
"LabelFeedURL": "Syötteen URL",
|
||||||
|
"LabelFetchingMetadata": "Noudetaan kuvailutietoja",
|
||||||
"LabelFile": "Tiedosto",
|
"LabelFile": "Tiedosto",
|
||||||
"LabelFileBirthtime": "Tiedoston syntymäaika",
|
"LabelFileBirthtime": "Tiedoston syntymäaika",
|
||||||
"LabelFileBornDate": "Syntynyt {0}",
|
"LabelFileBornDate": "Syntynyt {0}",
|
||||||
"LabelFileModified": "Muutettu tiedosto",
|
"LabelFileModified": "Muutettu tiedosto",
|
||||||
"LabelFileModifiedDate": "Muokattu {0}",
|
"LabelFileModifiedDate": "Muokattu {0}",
|
||||||
"LabelFilename": "Tiedostonimi",
|
"LabelFilename": "Tiedostonimi",
|
||||||
|
"LabelFilterByUser": "Suodata käyttäjien perusteella",
|
||||||
"LabelFindEpisodes": "Etsi jaksoja",
|
"LabelFindEpisodes": "Etsi jaksoja",
|
||||||
"LabelFinished": "Valmis",
|
"LabelFinished": "Valmis",
|
||||||
"LabelFolder": "Kansio",
|
"LabelFolder": "Kansio",
|
||||||
"LabelFolders": "Kansiot",
|
"LabelFolders": "Kansiot",
|
||||||
|
"LabelFontBold": "Lihavoitu",
|
||||||
|
"LabelFontBoldness": "Kirjasintyyppien lihavointi",
|
||||||
|
"LabelFontFamily": "Kirjasinperhe",
|
||||||
|
"LabelFontItalic": "Kursiivi",
|
||||||
|
"LabelFontScale": "Kirjasintyyppien skaalautuminen",
|
||||||
|
"LabelFontStrikethrough": "Yliviivattu",
|
||||||
|
"LabelFull": "Täynnä",
|
||||||
"LabelGenre": "Lajityyppi",
|
"LabelGenre": "Lajityyppi",
|
||||||
"LabelGenres": "Lajityypit",
|
"LabelGenres": "Lajityypit",
|
||||||
|
"LabelHighestPriority": "Tärkein",
|
||||||
"LabelHost": "Isäntä",
|
"LabelHost": "Isäntä",
|
||||||
"LabelHours": "Tunnit",
|
"LabelHours": "Tunnit",
|
||||||
|
"LabelIcon": "Kuvake",
|
||||||
|
"LabelImageURLFromTheWeb": "Kuvan verkko-osoite",
|
||||||
"LabelInProgress": "Kesken",
|
"LabelInProgress": "Kesken",
|
||||||
"LabelIncomplete": "Keskeneräinen",
|
"LabelIncomplete": "Keskeneräinen",
|
||||||
|
"LabelInterval": "Väli",
|
||||||
|
"LabelIntervalCustomDailyWeekly": "Mukautettu päivittäinen/viikoittainen",
|
||||||
"LabelIntervalEvery12Hours": "12 tunnin välein",
|
"LabelIntervalEvery12Hours": "12 tunnin välein",
|
||||||
"LabelIntervalEvery15Minutes": "15 minuutin välein",
|
"LabelIntervalEvery15Minutes": "15 minuutin välein",
|
||||||
"LabelIntervalEvery2Hours": "2 tunnin välein",
|
"LabelIntervalEvery2Hours": "2 tunnin välein",
|
||||||
@ -287,12 +359,36 @@
|
|||||||
"LabelLanguageDefaultServer": "Palvelimen oletuskieli",
|
"LabelLanguageDefaultServer": "Palvelimen oletuskieli",
|
||||||
"LabelLanguages": "Kielet",
|
"LabelLanguages": "Kielet",
|
||||||
"LabelLastBookAdded": "Viimeisin lisätty kirja",
|
"LabelLastBookAdded": "Viimeisin lisätty kirja",
|
||||||
|
"LabelLastBookUpdated": "Viimeisin päivitetty kirja",
|
||||||
|
"LabelLastSeen": "Nähty viimeksi",
|
||||||
|
"LabelLastUpdate": "Viimeisin päivitys",
|
||||||
|
"LabelLayout": "Asettelu",
|
||||||
|
"LabelLayoutSinglePage": "Yksi sivu",
|
||||||
|
"LabelLayoutSplitPage": "Jaa sivu osiin",
|
||||||
|
"LabelLess": "Vähemmän",
|
||||||
|
"LabelLibrariesAccessibleToUser": "Käyttäjälle saatavilla olevat kirjastot",
|
||||||
"LabelLibrary": "Kirjasto",
|
"LabelLibrary": "Kirjasto",
|
||||||
|
"LabelLibraryName": "Kirjaston nimi",
|
||||||
|
"LabelLimit": "Raja",
|
||||||
"LabelLineSpacing": "Riviväli",
|
"LabelLineSpacing": "Riviväli",
|
||||||
"LabelListenAgain": "Kuuntele uudelleen",
|
"LabelListenAgain": "Kuuntele uudelleen",
|
||||||
|
"LabelLogLevelInfo": "Tiedot",
|
||||||
|
"LabelLogLevelWarn": "Varoita",
|
||||||
|
"LabelLookForNewEpisodesAfterDate": "Etsi uusia jaksoja tämän päivämäärän jälkeen",
|
||||||
|
"LabelLowestPriority": "Vähiten tärkeä",
|
||||||
|
"LabelMaxEpisodesToDownload": "Jaksojen maksimilatausmäärä. 0 poistaa rajoituksen.",
|
||||||
|
"LabelMaxEpisodesToKeep": "Säilytettävien jaksojen enimmäismäärä",
|
||||||
|
"LabelMaxEpisodesToKeepHelp": "Jos arvona on 0, enimmäisrajaa ei ole. Kun uusi jakso ladataan automaattisesti, vanhin jakso poistetaan, jos jaksoja on yli X. Tämä poistaa vain yhden jakson uutta latauskertaa kohden.",
|
||||||
|
"LabelMediaPlayer": "Mediasoitin",
|
||||||
"LabelMediaType": "Mediatyyppi",
|
"LabelMediaType": "Mediatyyppi",
|
||||||
|
"LabelMetaTag": "Metatunniste",
|
||||||
|
"LabelMetaTags": "Metatunnisteet",
|
||||||
|
"LabelMetadataOrderOfPrecedenceDescription": "Tärkeämmät kuvailutietojen lähteet ohittavat vähemmän tärkeät lähteet",
|
||||||
|
"LabelMetadataProvider": "Kuvailutietojen toimittaja",
|
||||||
"LabelMinute": "Minuutti",
|
"LabelMinute": "Minuutti",
|
||||||
"LabelMinutes": "Minuutit",
|
"LabelMinutes": "Minuutit",
|
||||||
|
"LabelMissing": "Puuttuu",
|
||||||
|
"LabelMissingEbook": "Ei e-kirjaa",
|
||||||
"LabelMore": "Lisää",
|
"LabelMore": "Lisää",
|
||||||
"LabelMoreInfo": "Lisätietoja",
|
"LabelMoreInfo": "Lisätietoja",
|
||||||
"LabelName": "Nimi",
|
"LabelName": "Nimi",
|
||||||
@ -302,31 +398,62 @@
|
|||||||
"LabelNewPassword": "Uusi salasana",
|
"LabelNewPassword": "Uusi salasana",
|
||||||
"LabelNewestAuthors": "Uusimmat kirjailijat",
|
"LabelNewestAuthors": "Uusimmat kirjailijat",
|
||||||
"LabelNewestEpisodes": "Uusimmat jaksot",
|
"LabelNewestEpisodes": "Uusimmat jaksot",
|
||||||
|
"LabelNextBackupDate": "Seuraava varmuuskopiointipäivämäärä",
|
||||||
|
"LabelNextScheduledRun": "Seuraava ajastettu suorittaminen",
|
||||||
|
"LabelNoCustomMetadataProviders": "Ei mukautettuja kuvailutietojen toimittajia",
|
||||||
|
"LabelNoEpisodesSelected": "Jaksoja ei ole valittu",
|
||||||
|
"LabelNotFinished": "Ei valmis",
|
||||||
"LabelNotStarted": "Ei aloitettu",
|
"LabelNotStarted": "Ei aloitettu",
|
||||||
|
"LabelNotes": "Muistiinpanoja",
|
||||||
|
"LabelNotificationAvailableVariables": "Käytettävissä olevat muuttujat",
|
||||||
|
"LabelNotificationEvent": "Ilmoitustapahtuma",
|
||||||
|
"LabelNotificationsMaxFailedAttempts": "Epäonnistuneiden yritysten enimmäismäärä",
|
||||||
|
"LabelNotificationsMaxFailedAttemptsHelp": "Ilmoitukset poistetaan käytöstä, jos niiden lähettäminen epäonnistuu näin monta kertaa",
|
||||||
|
"LabelNotificationsMaxQueueSize": "Ilmoitustapahtumajonon enimmäispituus",
|
||||||
|
"LabelNumberOfBooks": "Kirjojen määrä",
|
||||||
|
"LabelNumberOfEpisodes": "Jaksojen määrä",
|
||||||
|
"LabelOverwrite": "Korvaa",
|
||||||
|
"LabelPaginationPageXOfY": "Sivu {0}/{1}",
|
||||||
"LabelPassword": "Salasana",
|
"LabelPassword": "Salasana",
|
||||||
"LabelPath": "Polku",
|
"LabelPath": "Polku",
|
||||||
"LabelPermanent": "Pysyvä",
|
"LabelPermanent": "Pysyvä",
|
||||||
"LabelPermissionsAccessAllLibraries": "Käyttöoikeudet kaikkiin kirjastoihin",
|
"LabelPermissionsAccessAllLibraries": "Käyttöoikeudet kaikkiin kirjastoihin",
|
||||||
|
"LabelPermissionsAccessAllTags": "Saa käyttää kaikkia tunnisteita",
|
||||||
|
"LabelPermissionsAccessExplicitContent": "Saa käyttää aikuisille tarkoitettua sisältöä",
|
||||||
"LabelPermissionsDelete": "Voi poistaa",
|
"LabelPermissionsDelete": "Voi poistaa",
|
||||||
"LabelPermissionsDownload": "Voi ladata",
|
"LabelPermissionsDownload": "Voi ladata",
|
||||||
"LabelPermissionsUpdate": "Voi päivittää",
|
"LabelPermissionsUpdate": "Voi päivittää",
|
||||||
"LabelPermissionsUpload": "Voi lähettää",
|
"LabelPermissionsUpload": "Voi lähettää",
|
||||||
|
"LabelPlayMethod": "Toistotapa",
|
||||||
|
"LabelPlayerChapterNumberMarker": "{0}/{1}",
|
||||||
"LabelPlaylists": "Soittolistat",
|
"LabelPlaylists": "Soittolistat",
|
||||||
"LabelPodcast": "Podcast",
|
"LabelPodcast": "Podcast",
|
||||||
|
"LabelPodcastSearchRegion": "Podcastien hakualue",
|
||||||
|
"LabelPodcastType": "Podcastien tyyppi",
|
||||||
"LabelPodcasts": "Podcastit",
|
"LabelPodcasts": "Podcastit",
|
||||||
"LabelPort": "Portti",
|
"LabelPort": "Portti",
|
||||||
|
"LabelPrimaryEbook": "Ensisijainen e-kirja",
|
||||||
|
"LabelProgress": "Edistyminen",
|
||||||
|
"LabelProvider": "Toimittaja",
|
||||||
|
"LabelPubDate": "Julkaisupäivä",
|
||||||
"LabelPublishYear": "Julkaisuvuosi",
|
"LabelPublishYear": "Julkaisuvuosi",
|
||||||
|
"LabelPublishedDate": "Julkaistu {0}",
|
||||||
"LabelPublisher": "Julkaisija",
|
"LabelPublisher": "Julkaisija",
|
||||||
"LabelPublishers": "Julkaisijat",
|
"LabelPublishers": "Julkaisijat",
|
||||||
"LabelRSSFeedPreventIndexing": "Estä indeksointi",
|
"LabelRSSFeedPreventIndexing": "Estä indeksointi",
|
||||||
"LabelRandomly": "Satunnaisesti",
|
"LabelRandomly": "Satunnaisesti",
|
||||||
"LabelRead": "Lue",
|
"LabelRead": "Lue",
|
||||||
"LabelReadAgain": "Lue uudelleen",
|
"LabelReadAgain": "Lue uudelleen",
|
||||||
|
"LabelReadEbookWithoutProgress": "Lue e-kirja tallentamatta edistymistietoja",
|
||||||
"LabelRecentSeries": "Viimeisimmät sarjat",
|
"LabelRecentSeries": "Viimeisimmät sarjat",
|
||||||
"LabelRecentlyAdded": "Viimeeksi lisätyt",
|
"LabelRecentlyAdded": "Viimeeksi lisätyt",
|
||||||
"LabelRecommended": "Suositeltu",
|
"LabelRecommended": "Suositeltu",
|
||||||
|
"LabelRedo": "Tee uudelleen",
|
||||||
"LabelRegion": "Alue",
|
"LabelRegion": "Alue",
|
||||||
|
"LabelReleaseDate": "Julkaisupäivä",
|
||||||
"LabelRemoveCover": "Poista kansikuva",
|
"LabelRemoveCover": "Poista kansikuva",
|
||||||
|
"LabelRowsPerPage": "Rivejä sivulla",
|
||||||
|
"LabelSearchTerm": "Hakusana",
|
||||||
"LabelSeason": "Kausi",
|
"LabelSeason": "Kausi",
|
||||||
"LabelSelectAll": "Valitse kaikki",
|
"LabelSelectAll": "Valitse kaikki",
|
||||||
"LabelSelectUsers": "Valitse käyttäjät",
|
"LabelSelectUsers": "Valitse käyttäjät",
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
"ButtonNext": "Suivant",
|
"ButtonNext": "Suivant",
|
||||||
"ButtonNextChapter": "Chapitre suivant",
|
"ButtonNextChapter": "Chapitre suivant",
|
||||||
"ButtonNextItemInQueue": "Élément suivant dans la file d’attente",
|
"ButtonNextItemInQueue": "Élément suivant dans la file d’attente",
|
||||||
"ButtonOk": "D’accord",
|
"ButtonOk": "D'accord",
|
||||||
"ButtonOpenFeed": "Ouvrir le flux",
|
"ButtonOpenFeed": "Ouvrir le flux",
|
||||||
"ButtonOpenManager": "Ouvrir le gestionnaire",
|
"ButtonOpenManager": "Ouvrir le gestionnaire",
|
||||||
"ButtonPause": "Pause",
|
"ButtonPause": "Pause",
|
||||||
@ -459,7 +459,7 @@
|
|||||||
"LabelNotificationsMaxQueueSize": "Nombres de notifications maximum à mettre en attente",
|
"LabelNotificationsMaxQueueSize": "Nombres de notifications maximum à mettre en attente",
|
||||||
"LabelNotificationsMaxQueueSizeHelp": "La limite de notification est de un évènement par seconde. Les notifications seront ignorées si la file d’attente est à son maximum. Cela empêche un flot trop important.",
|
"LabelNotificationsMaxQueueSizeHelp": "La limite de notification est de un évènement par seconde. Les notifications seront ignorées si la file d’attente est à son maximum. Cela empêche un flot trop important.",
|
||||||
"LabelNumberOfBooks": "Nombre de livres",
|
"LabelNumberOfBooks": "Nombre de livres",
|
||||||
"LabelNumberOfEpisodes": "Nombre d’épisodes",
|
"LabelNumberOfEpisodes": "Nombre d'épisodes",
|
||||||
"LabelOpenIDAdvancedPermsClaimDescription": "Nom de la demande OpenID qui contient des autorisations avancées pour les actions de l’utilisateur dans l’application, qui s’appliqueront à des rôles autres que celui d’administrateur (<b>s’il est configuré</b>). Si la demande est absente de la réponse, l’accès à ABS sera refusé. Si une seule option est manquante, elle sera considérée comme <code>false</code>. Assurez-vous que la demande du fournisseur d’identité correspond à la structure attendue :",
|
"LabelOpenIDAdvancedPermsClaimDescription": "Nom de la demande OpenID qui contient des autorisations avancées pour les actions de l’utilisateur dans l’application, qui s’appliqueront à des rôles autres que celui d’administrateur (<b>s’il est configuré</b>). Si la demande est absente de la réponse, l’accès à ABS sera refusé. Si une seule option est manquante, elle sera considérée comme <code>false</code>. Assurez-vous que la demande du fournisseur d’identité correspond à la structure attendue :",
|
||||||
"LabelOpenIDClaims": "Laissez les options suivantes vides pour désactiver l’attribution avancée de groupes et d’autorisations, en attribuant alors automatiquement le groupe « Utilisateur ».",
|
"LabelOpenIDClaims": "Laissez les options suivantes vides pour désactiver l’attribution avancée de groupes et d’autorisations, en attribuant alors automatiquement le groupe « Utilisateur ».",
|
||||||
"LabelOpenIDGroupClaimDescription": "Nom de la demande OpenID qui contient une liste des groupes de l’utilisateur. Communément appelé <code>groups</code>. <b>Si elle est configurée</b>, l’application attribuera automatiquement des rôles en fonction de l’appartenance de l’utilisateur à un groupe, à condition que ces groupes soient nommés -sensible à la casse- tel que « admin », « user » ou « guest » dans la demande. Elle doit contenir une liste, et si un utilisateur appartient à plusieurs groupes, l’application attribuera le rôle correspondant au niveau d’accès le plus élevé. Si aucun groupe ne correspond, l’accès sera refusé.",
|
"LabelOpenIDGroupClaimDescription": "Nom de la demande OpenID qui contient une liste des groupes de l’utilisateur. Communément appelé <code>groups</code>. <b>Si elle est configurée</b>, l’application attribuera automatiquement des rôles en fonction de l’appartenance de l’utilisateur à un groupe, à condition que ces groupes soient nommés -sensible à la casse- tel que « admin », « user » ou « guest » dans la demande. Elle doit contenir une liste, et si un utilisateur appartient à plusieurs groupes, l’application attribuera le rôle correspondant au niveau d’accès le plus élevé. Si aucun groupe ne correspond, l’accès sera refusé.",
|
||||||
@ -944,7 +944,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Échec de la création de signet",
|
"ToastBookmarkCreateFailed": "Échec de la création de signet",
|
||||||
"ToastBookmarkCreateSuccess": "Signet ajouté",
|
"ToastBookmarkCreateSuccess": "Signet ajouté",
|
||||||
"ToastBookmarkRemoveSuccess": "Signet supprimé",
|
"ToastBookmarkRemoveSuccess": "Signet supprimé",
|
||||||
"ToastBookmarkUpdateSuccess": "Signet mis à jour",
|
|
||||||
"ToastCachePurgeFailed": "Échec de la purge du cache",
|
"ToastCachePurgeFailed": "Échec de la purge du cache",
|
||||||
"ToastCachePurgeSuccess": "Cache purgé avec succès",
|
"ToastCachePurgeSuccess": "Cache purgé avec succès",
|
||||||
"ToastChaptersHaveErrors": "Les chapitres contiennent des erreurs",
|
"ToastChaptersHaveErrors": "Les chapitres contiennent des erreurs",
|
||||||
|
@ -740,7 +740,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "יצירת סימניה נכשלה",
|
"ToastBookmarkCreateFailed": "יצירת סימניה נכשלה",
|
||||||
"ToastBookmarkCreateSuccess": "הסימניה נוספה בהצלחה",
|
"ToastBookmarkCreateSuccess": "הסימניה נוספה בהצלחה",
|
||||||
"ToastBookmarkRemoveSuccess": "הסימניה הוסרה בהצלחה",
|
"ToastBookmarkRemoveSuccess": "הסימניה הוסרה בהצלחה",
|
||||||
"ToastBookmarkUpdateSuccess": "הסימניה עודכנה בהצלחה",
|
|
||||||
"ToastChaptersHaveErrors": "פרקים מכילים שגיאות",
|
"ToastChaptersHaveErrors": "פרקים מכילים שגיאות",
|
||||||
"ToastChaptersMustHaveTitles": "פרקים חייבים לכלול כותרות",
|
"ToastChaptersMustHaveTitles": "פרקים חייבים לכלול כותרות",
|
||||||
"ToastCollectionRemoveSuccess": "האוסף הוסר בהצלחה",
|
"ToastCollectionRemoveSuccess": "האוסף הוסר בהצלחה",
|
||||||
|
@ -300,6 +300,7 @@
|
|||||||
"LabelDiscover": "Otkrij",
|
"LabelDiscover": "Otkrij",
|
||||||
"LabelDownload": "Preuzmi",
|
"LabelDownload": "Preuzmi",
|
||||||
"LabelDownloadNEpisodes": "Preuzmi {0} nastavak/a",
|
"LabelDownloadNEpisodes": "Preuzmi {0} nastavak/a",
|
||||||
|
"LabelDownloadable": "Moguće preuzimanje",
|
||||||
"LabelDuration": "Trajanje",
|
"LabelDuration": "Trajanje",
|
||||||
"LabelDurationComparisonExactMatch": "(točno podudaranje)",
|
"LabelDurationComparisonExactMatch": "(točno podudaranje)",
|
||||||
"LabelDurationComparisonLonger": "({0} duže)",
|
"LabelDurationComparisonLonger": "({0} duže)",
|
||||||
@ -366,7 +367,7 @@
|
|||||||
"LabelFull": "Cijeli",
|
"LabelFull": "Cijeli",
|
||||||
"LabelGenre": "Žanr",
|
"LabelGenre": "Žanr",
|
||||||
"LabelGenres": "Žanrovi",
|
"LabelGenres": "Žanrovi",
|
||||||
"LabelHardDeleteFile": "Obriši datoteku zauvijek",
|
"LabelHardDeleteFile": "Izbriši datoteku zauvijek",
|
||||||
"LabelHasEbook": "Ima e-knjigu",
|
"LabelHasEbook": "Ima e-knjigu",
|
||||||
"LabelHasSupplementaryEbook": "Ima dopunsku e-knjigu",
|
"LabelHasSupplementaryEbook": "Ima dopunsku e-knjigu",
|
||||||
"LabelHideSubtitles": "Skrij podnaslove",
|
"LabelHideSubtitles": "Skrij podnaslove",
|
||||||
@ -588,6 +589,7 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "Meta-podatci se obično spremaju u /metadata/items; ako uključite ovu postavku meta-podatci će se čuvati u mapama knjižničkih stavki",
|
"LabelSettingsStoreMetadataWithItemHelp": "Meta-podatci se obično spremaju u /metadata/items; ako uključite ovu postavku meta-podatci će se čuvati u mapama knjižničkih stavki",
|
||||||
"LabelSettingsTimeFormat": "Format vremena",
|
"LabelSettingsTimeFormat": "Format vremena",
|
||||||
"LabelShare": "Podijeli",
|
"LabelShare": "Podijeli",
|
||||||
|
"LabelShareDownloadableHelp": "Korisnicima s poveznicom za dijeljenje omogućuje preuzimanje stavke.",
|
||||||
"LabelShareOpen": "Dijeljenje otvoreno",
|
"LabelShareOpen": "Dijeljenje otvoreno",
|
||||||
"LabelShareURL": "URL za dijeljenje",
|
"LabelShareURL": "URL za dijeljenje",
|
||||||
"LabelShowAll": "Prikaži sve",
|
"LabelShowAll": "Prikaži sve",
|
||||||
@ -715,15 +717,15 @@
|
|||||||
"MessageChapterStartIsAfter": "Početak poglavlja je nakon kraja zvučne knjige",
|
"MessageChapterStartIsAfter": "Početak poglavlja je nakon kraja zvučne knjige",
|
||||||
"MessageCheckingCron": "Provjeravam cron...",
|
"MessageCheckingCron": "Provjeravam cron...",
|
||||||
"MessageConfirmCloseFeed": "Sigurno želite zatvoriti ovaj izvor?",
|
"MessageConfirmCloseFeed": "Sigurno želite zatvoriti ovaj izvor?",
|
||||||
"MessageConfirmDeleteBackup": "Jeste li sigurni da želite obrisati backup za {0}?",
|
"MessageConfirmDeleteBackup": "Sigurno želite izbrisati sigurnosnu kopiju za {0}?",
|
||||||
"MessageConfirmDeleteDevice": "Sigurno želite izbrisati e-čitač \"{0}\"?",
|
"MessageConfirmDeleteDevice": "Sigurno želite izbrisati e-čitač \"{0}\"?",
|
||||||
"MessageConfirmDeleteFile": "Ovo će izbrisati datoteke s datotečnog sustava. Jeste li sigurni?",
|
"MessageConfirmDeleteFile": "Ovo će izbrisati datoteke s datotečnog sustava. Jeste li sigurni?",
|
||||||
"MessageConfirmDeleteLibrary": "Sigurno želite trajno obrisati knjižnicu \"{0}\"?",
|
"MessageConfirmDeleteLibrary": "Sigurno želite trajno izbrisati knjižnicu \"{0}\"?",
|
||||||
"MessageConfirmDeleteLibraryItem": "Ovo će izbrisati knjižničku stavku iz datoteke i vašeg datotečnog sustava. Jeste li sigurni?",
|
"MessageConfirmDeleteLibraryItem": "Ovo će izbrisati knjižničku stavku iz datoteke i vašeg datotečnog sustava. Jeste li sigurni?",
|
||||||
"MessageConfirmDeleteLibraryItems": "Ovo će izbrisati {0} knjižničkih stavki iz baze podataka i datotečnog sustava. Jeste li sigurni?",
|
"MessageConfirmDeleteLibraryItems": "Ovo će izbrisati {0} knjižničkih stavki iz baze podataka i datotečnog sustava. Jeste li sigurni?",
|
||||||
"MessageConfirmDeleteMetadataProvider": "Sigurno želite izbrisati prilagođenog pružatelja meta-podataka \"{0}\"?",
|
"MessageConfirmDeleteMetadataProvider": "Sigurno želite izbrisati prilagođenog pružatelja meta-podataka \"{0}\"?",
|
||||||
"MessageConfirmDeleteNotification": "Sigurno želite izbrisati ovu obavijest?",
|
"MessageConfirmDeleteNotification": "Sigurno želite izbrisati ovu obavijest?",
|
||||||
"MessageConfirmDeleteSession": "Sigurno želite obrisati ovu sesiju?",
|
"MessageConfirmDeleteSession": "Sigurno želite izbrisati ovu sesiju?",
|
||||||
"MessageConfirmEmbedMetadataInAudioFiles": "Sigurno želite ugraditi meta-podatke u {0} zvučnih datoteka?",
|
"MessageConfirmEmbedMetadataInAudioFiles": "Sigurno želite ugraditi meta-podatke u {0} zvučnih datoteka?",
|
||||||
"MessageConfirmForceReScan": "Sigurno želite ponovno pokrenuti skeniranje?",
|
"MessageConfirmForceReScan": "Sigurno želite ponovno pokrenuti skeniranje?",
|
||||||
"MessageConfirmMarkAllEpisodesFinished": "Sigurno želite označiti sve nastavke dovršenima?",
|
"MessageConfirmMarkAllEpisodesFinished": "Sigurno želite označiti sve nastavke dovršenima?",
|
||||||
@ -754,8 +756,9 @@
|
|||||||
"MessageConfirmRenameTagMergeNote": "Napomena: Ova oznaka već postoji, stoga će biti pripojena.",
|
"MessageConfirmRenameTagMergeNote": "Napomena: Ova oznaka već postoji, stoga će biti pripojena.",
|
||||||
"MessageConfirmRenameTagWarning": "Pažnja! Slična oznaka s drugačijim velikim i malim slovima već postoji \"{0}\".",
|
"MessageConfirmRenameTagWarning": "Pažnja! Slična oznaka s drugačijim velikim i malim slovima već postoji \"{0}\".",
|
||||||
"MessageConfirmResetProgress": "Sigurno želite resetirati napredak?",
|
"MessageConfirmResetProgress": "Sigurno želite resetirati napredak?",
|
||||||
"MessageConfirmSendEbookToDevice": "Sigurno želite poslati {0} e-knjiga/u \"{1}\" na uređaj \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "Sigurno želite poslati {0} e-knjigu \"{1}\" na uređaj \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "Sigurno želite odspojiti ovog korisnika s OpenID-ja?",
|
"MessageConfirmUnlinkOpenId": "Sigurno želite odspojiti ovog korisnika s OpenID-ja?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} dana slušanja u posljednjih godinu dana",
|
||||||
"MessageDownloadingEpisode": "Preuzimam nastavak",
|
"MessageDownloadingEpisode": "Preuzimam nastavak",
|
||||||
"MessageDragFilesIntoTrackOrder": "Prevlačenjem datoteka složite pravilan redoslijed",
|
"MessageDragFilesIntoTrackOrder": "Prevlačenjem datoteka složite pravilan redoslijed",
|
||||||
"MessageEmbedFailed": "Ugrađivanje nije uspjelo!",
|
"MessageEmbedFailed": "Ugrađivanje nije uspjelo!",
|
||||||
@ -829,11 +832,12 @@
|
|||||||
"MessageRemoveChapter": "Ukloni poglavlje",
|
"MessageRemoveChapter": "Ukloni poglavlje",
|
||||||
"MessageRemoveEpisodes": "Ukloni {0} nastavaka",
|
"MessageRemoveEpisodes": "Ukloni {0} nastavaka",
|
||||||
"MessageRemoveFromPlayerQueue": "Ukloni iz redoslijeda izvođenja",
|
"MessageRemoveFromPlayerQueue": "Ukloni iz redoslijeda izvođenja",
|
||||||
"MessageRemoveUserWarning": "Sigurno želite trajno obrisati korisnika \"{0}\"?",
|
"MessageRemoveUserWarning": "Sigurno želite trajno izbrisati korisnika \"{0}\"?",
|
||||||
"MessageReportBugsAndContribute": "Prijavite pogreške, zatražite funkcionalnosti i doprinesite na",
|
"MessageReportBugsAndContribute": "Prijavite pogreške, zatražite funkcionalnosti i doprinesite na",
|
||||||
"MessageResetChaptersConfirm": "Sigurno želite vratiti poglavlja na prethodno stanje i poništiti učinjene promjene?",
|
"MessageResetChaptersConfirm": "Sigurno želite vratiti poglavlja na prethodno stanje i poništiti učinjene promjene?",
|
||||||
"MessageRestoreBackupConfirm": "Sigurno želite vratiti sigurnosnu kopiju izrađenu",
|
"MessageRestoreBackupConfirm": "Sigurno želite vratiti sigurnosnu kopiju izrađenu",
|
||||||
"MessageRestoreBackupWarning": "Vraćanjem sigurnosne kopije prepisat ćete cijelu bazu podataka koja se nalazi u /config i slike naslovnice u /metadata/items i /metadata/authors.<br /><br />Sigurnosne kopije ne mijenjaju datoteke koje se nalaze u mapama vaših knjižnica. Ako ste u postavkama poslužitelja uključili mogućnost spremanja naslovnica i meta-podataka u mape knjižnice, te se datoteke neće niti sigurnosno pohraniti niti prepisati. <br /><br />Svi klijenti koji se spajaju na vaš poslužitelj automatski će se osvježiti.",
|
"MessageRestoreBackupWarning": "Vraćanjem sigurnosne kopije prepisat ćete cijelu bazu podataka koja se nalazi u /config i slike naslovnice u /metadata/items i /metadata/authors.<br /><br />Sigurnosne kopije ne mijenjaju datoteke koje se nalaze u mapama vaših knjižnica. Ako ste u postavkama poslužitelja uključili mogućnost spremanja naslovnica i meta-podataka u mape knjižnice, te se datoteke neće niti sigurnosno pohraniti niti prepisati. <br /><br />Svi klijenti koji se spajaju na vaš poslužitelj automatski će se osvježiti.",
|
||||||
|
"MessageScheduleLibraryScanNote": "Za većinu korisnika se preporučuje ostaviti ovu funkciju deaktiviranom i ostaviti postavku promatrača mape aktiviranom. Promatrač mapa će automatski otkriti promjene u mapama vaše knjižnice. Promatrač mapa ne radi na svakom datotečnom sustavu (kao što je NFS) pa se umjesto njega mogu koristiti planirana pretraživanja knjižnice.",
|
||||||
"MessageSearchResultsFor": "Rezultati pretrage za",
|
"MessageSearchResultsFor": "Rezultati pretrage za",
|
||||||
"MessageSelected": "{0} odabrano",
|
"MessageSelected": "{0} odabrano",
|
||||||
"MessageServerCouldNotBeReached": "Nije moguće pristupiti poslužitelju",
|
"MessageServerCouldNotBeReached": "Nije moguće pristupiti poslužitelju",
|
||||||
@ -909,7 +913,7 @@
|
|||||||
"StatsBooksFinished": "knjiga dovršeno",
|
"StatsBooksFinished": "knjiga dovršeno",
|
||||||
"StatsBooksFinishedThisYear": "Neke knjige dovršene ove godine…",
|
"StatsBooksFinishedThisYear": "Neke knjige dovršene ove godine…",
|
||||||
"StatsBooksListenedTo": "knjiga slušano",
|
"StatsBooksListenedTo": "knjiga slušano",
|
||||||
"StatsCollectionGrewTo": "Vaša zbirka knjiga narasla je na…",
|
"StatsCollectionGrewTo": "Vaša je zbirka knjiga narasla na…",
|
||||||
"StatsSessions": "sesija",
|
"StatsSessions": "sesija",
|
||||||
"StatsSpentListening": "provedeno u slušanju",
|
"StatsSpentListening": "provedeno u slušanju",
|
||||||
"StatsTopAuthor": "NAJPOPULARNIJI AUTOR",
|
"StatsTopAuthor": "NAJPOPULARNIJI AUTOR",
|
||||||
@ -932,7 +936,7 @@
|
|||||||
"ToastAuthorUpdateSuccess": "Autor ažuriran",
|
"ToastAuthorUpdateSuccess": "Autor ažuriran",
|
||||||
"ToastAuthorUpdateSuccessNoImageFound": "Autor ažuriran (slika nije pronađena)",
|
"ToastAuthorUpdateSuccessNoImageFound": "Autor ažuriran (slika nije pronađena)",
|
||||||
"ToastBackupAppliedSuccess": "Sigurnosna kopija vraćena",
|
"ToastBackupAppliedSuccess": "Sigurnosna kopija vraćena",
|
||||||
"ToastBackupCreateFailed": "Neuspješno kreiranje backupa",
|
"ToastBackupCreateFailed": "Izrada sigurnosne kopije nije uspjela",
|
||||||
"ToastBackupCreateSuccess": "Izrađena sigurnosna kopija",
|
"ToastBackupCreateSuccess": "Izrađena sigurnosna kopija",
|
||||||
"ToastBackupDeleteFailed": "Brisanje sigurnosne kopije nije uspjelo",
|
"ToastBackupDeleteFailed": "Brisanje sigurnosne kopije nije uspjelo",
|
||||||
"ToastBackupDeleteSuccess": "Sigurnosna kopija izbrisana",
|
"ToastBackupDeleteSuccess": "Sigurnosna kopija izbrisana",
|
||||||
@ -942,7 +946,7 @@
|
|||||||
"ToastBackupUploadFailed": "Učitavanje sigurnosne kopije nije uspjelo",
|
"ToastBackupUploadFailed": "Učitavanje sigurnosne kopije nije uspjelo",
|
||||||
"ToastBackupUploadSuccess": "Sigurnosna kopija učitana",
|
"ToastBackupUploadSuccess": "Sigurnosna kopija učitana",
|
||||||
"ToastBatchDeleteFailed": "Grupno brisanje nije uspjelo",
|
"ToastBatchDeleteFailed": "Grupno brisanje nije uspjelo",
|
||||||
"ToastBatchDeleteSuccess": "Grupno brisanje je uspješno dovršeno",
|
"ToastBatchDeleteSuccess": "Grupno brisanje je uspjelo",
|
||||||
"ToastBatchQuickMatchFailed": "Grupno brzo prepoznavanje nije uspjelo!",
|
"ToastBatchQuickMatchFailed": "Grupno brzo prepoznavanje nije uspjelo!",
|
||||||
"ToastBatchQuickMatchStarted": "Započelo je brzo prepoznavanje {0} knjiga!",
|
"ToastBatchQuickMatchStarted": "Započelo je brzo prepoznavanje {0} knjiga!",
|
||||||
"ToastBatchUpdateFailed": "Skupno ažuriranje nije uspjelo",
|
"ToastBatchUpdateFailed": "Skupno ažuriranje nije uspjelo",
|
||||||
@ -950,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Izrada knjižne oznake nije uspjela",
|
"ToastBookmarkCreateFailed": "Izrada knjižne oznake nije uspjela",
|
||||||
"ToastBookmarkCreateSuccess": "Knjižna oznaka dodana",
|
"ToastBookmarkCreateSuccess": "Knjižna oznaka dodana",
|
||||||
"ToastBookmarkRemoveSuccess": "Knjižna oznaka uklonjena",
|
"ToastBookmarkRemoveSuccess": "Knjižna oznaka uklonjena",
|
||||||
"ToastBookmarkUpdateSuccess": "Knjižna oznaka ažurirana",
|
|
||||||
"ToastCachePurgeFailed": "Čišćenje predmemorije nije uspjelo",
|
"ToastCachePurgeFailed": "Čišćenje predmemorije nije uspjelo",
|
||||||
"ToastCachePurgeSuccess": "Predmemorija uspješno očišćena",
|
"ToastCachePurgeSuccess": "Predmemorija uspješno očišćena",
|
||||||
"ToastChaptersHaveErrors": "Poglavlja imaju pogreške",
|
"ToastChaptersHaveErrors": "Poglavlja imaju pogreške",
|
||||||
@ -961,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Zbirka izbrisana",
|
"ToastCollectionRemoveSuccess": "Zbirka izbrisana",
|
||||||
"ToastCollectionUpdateSuccess": "Zbirka ažurirana",
|
"ToastCollectionUpdateSuccess": "Zbirka ažurirana",
|
||||||
"ToastCoverUpdateFailed": "Ažuriranje naslovnice nije uspjelo",
|
"ToastCoverUpdateFailed": "Ažuriranje naslovnice nije uspjelo",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Datum i vrijeme su neispravni ili nepotpuni",
|
||||||
"ToastDeleteFileFailed": "Brisanje datoteke nije uspjelo",
|
"ToastDeleteFileFailed": "Brisanje datoteke nije uspjelo",
|
||||||
"ToastDeleteFileSuccess": "Datoteka izbrisana",
|
"ToastDeleteFileSuccess": "Datoteka izbrisana",
|
||||||
"ToastDeviceAddFailed": "Dodavanje uređaja nije uspjelo",
|
"ToastDeviceAddFailed": "Dodavanje uređaja nije uspjelo",
|
||||||
@ -1013,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Potrebno je odabrati najmanje jednu oznaku",
|
"ToastNewUserTagError": "Potrebno je odabrati najmanje jednu oznaku",
|
||||||
"ToastNewUserUsernameError": "Upišite korisničko ime",
|
"ToastNewUserUsernameError": "Upišite korisničko ime",
|
||||||
"ToastNoNewEpisodesFound": "Nisu pronađeni novi nastavci",
|
"ToastNoNewEpisodesFound": "Nisu pronađeni novi nastavci",
|
||||||
|
"ToastNoRSSFeed": "Podcast nema RSS izvor",
|
||||||
"ToastNoUpdatesNecessary": "Ažuriranja nisu potrebna",
|
"ToastNoUpdatesNecessary": "Ažuriranja nisu potrebna",
|
||||||
"ToastNotificationCreateFailed": "Stvaranje obavijesti nije uspjelo",
|
"ToastNotificationCreateFailed": "Stvaranje obavijesti nije uspjelo",
|
||||||
"ToastNotificationDeleteFailed": "Brisanje obavijesti nije uspjelo",
|
"ToastNotificationDeleteFailed": "Brisanje obavijesti nije uspjelo",
|
||||||
@ -1039,7 +1044,7 @@
|
|||||||
"ToastRSSFeedCloseFailed": "RSS izvor nije uspješno zatvoren",
|
"ToastRSSFeedCloseFailed": "RSS izvor nije uspješno zatvoren",
|
||||||
"ToastRSSFeedCloseSuccess": "RSS izvor zatvoren",
|
"ToastRSSFeedCloseSuccess": "RSS izvor zatvoren",
|
||||||
"ToastRemoveFailed": "Uklanjanje nije uspjelo",
|
"ToastRemoveFailed": "Uklanjanje nije uspjelo",
|
||||||
"ToastRemoveItemFromCollectionFailed": "Neuspješno uklanjanje stavke iz zbirke",
|
"ToastRemoveItemFromCollectionFailed": "Uklanjanje stavke iz zbirke nije uspjelo",
|
||||||
"ToastRemoveItemFromCollectionSuccess": "Stavka uklonjena iz zbirke",
|
"ToastRemoveItemFromCollectionSuccess": "Stavka uklonjena iz zbirke",
|
||||||
"ToastRemoveItemsWithIssuesFailed": "Uklanjanje knjižničkih stavki s problemima nije uspjelo",
|
"ToastRemoveItemsWithIssuesFailed": "Uklanjanje knjižničkih stavki s problemima nije uspjelo",
|
||||||
"ToastRemoveItemsWithIssuesSuccess": "Uspješno uklonjene knjižničke stavke s problemima",
|
"ToastRemoveItemsWithIssuesSuccess": "Uspješno uklonjene knjižničke stavke s problemima",
|
||||||
@ -1056,8 +1061,8 @@
|
|||||||
"ToastSeriesUpdateSuccess": "Serijal uspješno ažuriran",
|
"ToastSeriesUpdateSuccess": "Serijal uspješno ažuriran",
|
||||||
"ToastServerSettingsUpdateSuccess": "Postavke poslužitelja ažurirane",
|
"ToastServerSettingsUpdateSuccess": "Postavke poslužitelja ažurirane",
|
||||||
"ToastSessionCloseFailed": "Zatvaranje sesije nije uspjelo",
|
"ToastSessionCloseFailed": "Zatvaranje sesije nije uspjelo",
|
||||||
"ToastSessionDeleteFailed": "Neuspješno brisanje serije",
|
"ToastSessionDeleteFailed": "Brisanje sesije nije uspjelo",
|
||||||
"ToastSessionDeleteSuccess": "Sesija obrisana",
|
"ToastSessionDeleteSuccess": "Sesija izbrisana",
|
||||||
"ToastSleepTimerDone": "Timer za spavanje istječe... zZzzZz",
|
"ToastSleepTimerDone": "Timer za spavanje istječe... zZzzZz",
|
||||||
"ToastSlugMustChange": "Slug sadrži nedozvoljene znakove",
|
"ToastSlugMustChange": "Slug sadrži nedozvoljene znakove",
|
||||||
"ToastSlugRequired": "Slug je obavezan",
|
"ToastSlugRequired": "Slug je obavezan",
|
||||||
@ -1070,8 +1075,8 @@
|
|||||||
"ToastUnknownError": "Nepoznata pogreška",
|
"ToastUnknownError": "Nepoznata pogreška",
|
||||||
"ToastUnlinkOpenIdFailed": "Uklanjanje OpenID veze korisnika nije uspjelo",
|
"ToastUnlinkOpenIdFailed": "Uklanjanje OpenID veze korisnika nije uspjelo",
|
||||||
"ToastUnlinkOpenIdSuccess": "Korisnik odspojen od OpenID-ja",
|
"ToastUnlinkOpenIdSuccess": "Korisnik odspojen od OpenID-ja",
|
||||||
"ToastUserDeleteFailed": "Neuspješno brisanje korisnika",
|
"ToastUserDeleteFailed": "Brisanje korisnika nije uspjelo",
|
||||||
"ToastUserDeleteSuccess": "Korisnik obrisan",
|
"ToastUserDeleteSuccess": "Korisnik izbrisan",
|
||||||
"ToastUserPasswordChangeSuccess": "Zaporka je uspješno promijenjena",
|
"ToastUserPasswordChangeSuccess": "Zaporka je uspješno promijenjena",
|
||||||
"ToastUserPasswordMismatch": "Zaporke se ne podudaraju",
|
"ToastUserPasswordMismatch": "Zaporke se ne podudaraju",
|
||||||
"ToastUserPasswordMustChange": "Nova zaporka ne smije biti jednaka staroj",
|
"ToastUserPasswordMustChange": "Nova zaporka ne smije biti jednaka staroj",
|
||||||
|
@ -100,7 +100,7 @@
|
|||||||
"ButtonStartM4BEncode": "M4B kódolás indítása",
|
"ButtonStartM4BEncode": "M4B kódolás indítása",
|
||||||
"ButtonStartMetadataEmbed": "Metaadatok beágyazásának indítása",
|
"ButtonStartMetadataEmbed": "Metaadatok beágyazásának indítása",
|
||||||
"ButtonStats": "Statisztikák",
|
"ButtonStats": "Statisztikák",
|
||||||
"ButtonSubmit": "Beküldés",
|
"ButtonSubmit": "Küldés",
|
||||||
"ButtonTest": "Teszt",
|
"ButtonTest": "Teszt",
|
||||||
"ButtonUnlinkOpenId": "OpenID szétkapcsolása",
|
"ButtonUnlinkOpenId": "OpenID szétkapcsolása",
|
||||||
"ButtonUpload": "Feltöltés",
|
"ButtonUpload": "Feltöltés",
|
||||||
@ -143,7 +143,7 @@
|
|||||||
"HeaderFindChapters": "Fejezetek keresése",
|
"HeaderFindChapters": "Fejezetek keresése",
|
||||||
"HeaderIgnoredFiles": "Figyelmen kívül hagyott fájlok",
|
"HeaderIgnoredFiles": "Figyelmen kívül hagyott fájlok",
|
||||||
"HeaderItemFiles": "Elemfájlok",
|
"HeaderItemFiles": "Elemfájlok",
|
||||||
"HeaderItemMetadataUtils": "Elem metaadat eszközök",
|
"HeaderItemMetadataUtils": "Metaadatok eszközei",
|
||||||
"HeaderLastListeningSession": "Utolsó hallgatási munkamenet",
|
"HeaderLastListeningSession": "Utolsó hallgatási munkamenet",
|
||||||
"HeaderLatestEpisodes": "Legújabb epizódok",
|
"HeaderLatestEpisodes": "Legújabb epizódok",
|
||||||
"HeaderLibraries": "Könyvtárak",
|
"HeaderLibraries": "Könyvtárak",
|
||||||
@ -165,6 +165,7 @@
|
|||||||
"HeaderNotificationUpdate": "Értesítés frissítése",
|
"HeaderNotificationUpdate": "Értesítés frissítése",
|
||||||
"HeaderNotifications": "Értesítések",
|
"HeaderNotifications": "Értesítések",
|
||||||
"HeaderOpenIDConnectAuthentication": "OpenID Connect hitelesítés",
|
"HeaderOpenIDConnectAuthentication": "OpenID Connect hitelesítés",
|
||||||
|
"HeaderOpenListeningSessions": "Hallgatási menetek megnyitása",
|
||||||
"HeaderOpenRSSFeed": "RSS hírcsatorna megnyitása",
|
"HeaderOpenRSSFeed": "RSS hírcsatorna megnyitása",
|
||||||
"HeaderOtherFiles": "Egyéb fájlok",
|
"HeaderOtherFiles": "Egyéb fájlok",
|
||||||
"HeaderPasswordAuthentication": "Jelszó hitelesítés",
|
"HeaderPasswordAuthentication": "Jelszó hitelesítés",
|
||||||
@ -194,7 +195,7 @@
|
|||||||
"HeaderSettingsWebClient": "Webkliens",
|
"HeaderSettingsWebClient": "Webkliens",
|
||||||
"HeaderSleepTimer": "Alvásidőzítő",
|
"HeaderSleepTimer": "Alvásidőzítő",
|
||||||
"HeaderStatsLargestItems": "Legnagyobb elemek",
|
"HeaderStatsLargestItems": "Legnagyobb elemek",
|
||||||
"HeaderStatsLongestItems": "Leghosszabb elemek (órákban)",
|
"HeaderStatsLongestItems": "Leghosszabb elemek (órában)",
|
||||||
"HeaderStatsMinutesListeningChart": "Hallgatási grafikon percekben (az elmúlt 7 napból)",
|
"HeaderStatsMinutesListeningChart": "Hallgatási grafikon percekben (az elmúlt 7 napból)",
|
||||||
"HeaderStatsRecentSessions": "Legutóbbi munkamenetek",
|
"HeaderStatsRecentSessions": "Legutóbbi munkamenetek",
|
||||||
"HeaderStatsTop10Authors": "Top 10 szerző",
|
"HeaderStatsTop10Authors": "Top 10 szerző",
|
||||||
@ -206,7 +207,7 @@
|
|||||||
"HeaderUpdateDetails": "Részletek frissítése",
|
"HeaderUpdateDetails": "Részletek frissítése",
|
||||||
"HeaderUpdateLibrary": "Könyvtár frissítése",
|
"HeaderUpdateLibrary": "Könyvtár frissítése",
|
||||||
"HeaderUsers": "Felhasználók",
|
"HeaderUsers": "Felhasználók",
|
||||||
"HeaderYearReview": "{0} év visszatekintése",
|
"HeaderYearReview": "Visszatekintés {0} -ra/re",
|
||||||
"HeaderYourStats": "Saját statisztikák",
|
"HeaderYourStats": "Saját statisztikák",
|
||||||
"LabelAbridged": "Tömörített",
|
"LabelAbridged": "Tömörített",
|
||||||
"LabelAbridgedChecked": "Rövidített (ellenőrizve)",
|
"LabelAbridgedChecked": "Rövidített (ellenőrizve)",
|
||||||
@ -237,7 +238,7 @@
|
|||||||
"LabelAuthor": "Szerző",
|
"LabelAuthor": "Szerző",
|
||||||
"LabelAuthorFirstLast": "Szerző (Keresztnév Vezetéknév)",
|
"LabelAuthorFirstLast": "Szerző (Keresztnév Vezetéknév)",
|
||||||
"LabelAuthorLastFirst": "Szerző (Vezetéknév, Keresztnév)",
|
"LabelAuthorLastFirst": "Szerző (Vezetéknév, Keresztnév)",
|
||||||
"LabelAuthors": "Szerzők",
|
"LabelAuthors": "Szerző",
|
||||||
"LabelAutoDownloadEpisodes": "Epizódok automatikus letöltése",
|
"LabelAutoDownloadEpisodes": "Epizódok automatikus letöltése",
|
||||||
"LabelAutoFetchMetadata": "Metaadatok automatikus lekérése",
|
"LabelAutoFetchMetadata": "Metaadatok automatikus lekérése",
|
||||||
"LabelAutoFetchMetadataHelp": "Cím, szerző és sorozat metaadatok automatikus lekérése a feltöltés megkönnyítése érdekében. További metaadatok egyeztetése szükséges lehet a feltöltés után.",
|
"LabelAutoFetchMetadataHelp": "Cím, szerző és sorozat metaadatok automatikus lekérése a feltöltés megkönnyítése érdekében. További metaadatok egyeztetése szükséges lehet a feltöltés után.",
|
||||||
@ -272,7 +273,7 @@
|
|||||||
"LabelCollapseSeries": "Sorozat összecsukása",
|
"LabelCollapseSeries": "Sorozat összecsukása",
|
||||||
"LabelCollapseSubSeries": "Alszéria összecsukása",
|
"LabelCollapseSubSeries": "Alszéria összecsukása",
|
||||||
"LabelCollection": "Gyűjtemény",
|
"LabelCollection": "Gyűjtemény",
|
||||||
"LabelCollections": "Gyűjtemények",
|
"LabelCollections": "Gyűjtemény",
|
||||||
"LabelComplete": "Kész",
|
"LabelComplete": "Kész",
|
||||||
"LabelConfirmPassword": "Jelszó megerősítése",
|
"LabelConfirmPassword": "Jelszó megerősítése",
|
||||||
"LabelContinueListening": "Hallgatás folytatása",
|
"LabelContinueListening": "Hallgatás folytatása",
|
||||||
@ -299,6 +300,7 @@
|
|||||||
"LabelDiscover": "Felfedezés",
|
"LabelDiscover": "Felfedezés",
|
||||||
"LabelDownload": "Letöltés",
|
"LabelDownload": "Letöltés",
|
||||||
"LabelDownloadNEpisodes": "{0} epizód letöltése",
|
"LabelDownloadNEpisodes": "{0} epizód letöltése",
|
||||||
|
"LabelDownloadable": "Letölthető",
|
||||||
"LabelDuration": "Időtartam",
|
"LabelDuration": "Időtartam",
|
||||||
"LabelDurationComparisonExactMatch": "(pontos egyezés)",
|
"LabelDurationComparisonExactMatch": "(pontos egyezés)",
|
||||||
"LabelDurationComparisonLonger": "({0}-val hosszabb)",
|
"LabelDurationComparisonLonger": "({0}-val hosszabb)",
|
||||||
@ -320,6 +322,7 @@
|
|||||||
"LabelEncodingChaptersNotEmbedded": "A fejezetek nincsenek beágyazva a többsávos hangoskönyvekbe.",
|
"LabelEncodingChaptersNotEmbedded": "A fejezetek nincsenek beágyazva a többsávos hangoskönyvekbe.",
|
||||||
"LabelEncodingClearItemCache": "Győződjön meg róla, hogy rendszeresen tisztítja az elemek gyorsítótárát.",
|
"LabelEncodingClearItemCache": "Győződjön meg róla, hogy rendszeresen tisztítja az elemek gyorsítótárát.",
|
||||||
"LabelEncodingFinishedM4B": "A kész M4B a hangoskönyv mappádba kerül:",
|
"LabelEncodingFinishedM4B": "A kész M4B a hangoskönyv mappádba kerül:",
|
||||||
|
"LabelEncodingInfoEmbedded": "A metaadatok beépülnek a hangsávokba a hangoskönyv mappáján belül.",
|
||||||
"LabelEncodingStartedNavigation": "Ha a feladat elindult, el lehet navigálni erről az oldalról.",
|
"LabelEncodingStartedNavigation": "Ha a feladat elindult, el lehet navigálni erről az oldalról.",
|
||||||
"LabelEncodingTimeWarning": "A kódolás akár 30 percet is igénybe vehet.",
|
"LabelEncodingTimeWarning": "A kódolás akár 30 percet is igénybe vehet.",
|
||||||
"LabelEncodingWarningAdvancedSettings": "Figyelmeztetés: Ne frissítse ezeket a beállításokat, hacsak nem ismeri az ffmpeg kódolási beállításait.",
|
"LabelEncodingWarningAdvancedSettings": "Figyelmeztetés: Ne frissítse ezeket a beállításokat, hacsak nem ismeri az ffmpeg kódolási beállításait.",
|
||||||
@ -441,7 +444,7 @@
|
|||||||
"LabelNarrators": "Előadók",
|
"LabelNarrators": "Előadók",
|
||||||
"LabelNew": "Új",
|
"LabelNew": "Új",
|
||||||
"LabelNewPassword": "Új jelszó",
|
"LabelNewPassword": "Új jelszó",
|
||||||
"LabelNewestAuthors": "Legújabb szerzők",
|
"LabelNewestAuthors": "A legújabb szerzők",
|
||||||
"LabelNewestEpisodes": "Legújabb epizódok",
|
"LabelNewestEpisodes": "Legújabb epizódok",
|
||||||
"LabelNextBackupDate": "Következő biztonsági másolat dátuma",
|
"LabelNextBackupDate": "Következő biztonsági másolat dátuma",
|
||||||
"LabelNextScheduledRun": "Következő ütemezett futtatás",
|
"LabelNextScheduledRun": "Következő ütemezett futtatás",
|
||||||
@ -478,7 +481,7 @@
|
|||||||
"LabelPermissionsDownload": "Letölthet",
|
"LabelPermissionsDownload": "Letölthet",
|
||||||
"LabelPermissionsUpdate": "Frissíthet",
|
"LabelPermissionsUpdate": "Frissíthet",
|
||||||
"LabelPermissionsUpload": "Feltölthet",
|
"LabelPermissionsUpload": "Feltölthet",
|
||||||
"LabelPersonalYearReview": "Az évvisszatekintésed ({0})",
|
"LabelPersonalYearReview": "Az éved összefoglalása ({0})",
|
||||||
"LabelPhotoPathURL": "Fénykép útvonal/URL",
|
"LabelPhotoPathURL": "Fénykép útvonal/URL",
|
||||||
"LabelPlayMethod": "Lejátszási módszer",
|
"LabelPlayMethod": "Lejátszási módszer",
|
||||||
"LabelPlayerChapterNumberMarker": "{0} a {1} -ből",
|
"LabelPlayerChapterNumberMarker": "{0} a {1} -ből",
|
||||||
@ -535,11 +538,12 @@
|
|||||||
"LabelSelectUsers": "Felhasználók kiválasztása",
|
"LabelSelectUsers": "Felhasználók kiválasztása",
|
||||||
"LabelSendEbookToDevice": "E-könyv küldése...",
|
"LabelSendEbookToDevice": "E-könyv küldése...",
|
||||||
"LabelSequence": "Sorozat",
|
"LabelSequence": "Sorozat",
|
||||||
|
"LabelSerial": "Sorozat",
|
||||||
"LabelSeries": "Sorozat",
|
"LabelSeries": "Sorozat",
|
||||||
"LabelSeriesName": "Sorozat neve",
|
"LabelSeriesName": "Sorozat neve",
|
||||||
"LabelSeriesProgress": "Sorozat haladása",
|
"LabelSeriesProgress": "Sorozat haladása",
|
||||||
"LabelServerLogLevel": "Kiszolgáló naplózási szint",
|
"LabelServerLogLevel": "Kiszolgáló naplózási szint",
|
||||||
"LabelServerYearReview": "Szerver évvisszatekintés ({0})",
|
"LabelServerYearReview": "Szerver éves visszatekintése ({0})",
|
||||||
"LabelSetEbookAsPrimary": "Beállítás elsődlegesként",
|
"LabelSetEbookAsPrimary": "Beállítás elsődlegesként",
|
||||||
"LabelSetEbookAsSupplementary": "Beállítás kiegészítőként",
|
"LabelSetEbookAsSupplementary": "Beállítás kiegészítőként",
|
||||||
"LabelSettingsAllowIframe": "A beágyazás engedélyezése egy iframe-be",
|
"LabelSettingsAllowIframe": "A beágyazás engedélyezése egy iframe-be",
|
||||||
@ -585,7 +589,11 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "Alapértelmezés szerint a metaadatfájlok a /metadata/items mappában vannak tárolva, ennek a beállításnak az engedélyezése a metaadatfájlokat a könyvtári elem mappáiban tárolja",
|
"LabelSettingsStoreMetadataWithItemHelp": "Alapértelmezés szerint a metaadatfájlok a /metadata/items mappában vannak tárolva, ennek a beállításnak az engedélyezése a metaadatfájlokat a könyvtári elem mappáiban tárolja",
|
||||||
"LabelSettingsTimeFormat": "Időformátum",
|
"LabelSettingsTimeFormat": "Időformátum",
|
||||||
"LabelShare": "Megosztás",
|
"LabelShare": "Megosztás",
|
||||||
|
"LabelShareDownloadableHelp": "Lehetővé teszi a megosztási linket birtokló felhasználók számára, hogy letöltsék a könyvtári elem zip-fájlját.",
|
||||||
|
"LabelShareOpen": "Megosztás megnyitása",
|
||||||
|
"LabelShareURL": "URL megosztása",
|
||||||
"LabelShowAll": "Mindent mutat",
|
"LabelShowAll": "Mindent mutat",
|
||||||
|
"LabelShowSeconds": "Másodperc megjelenítése",
|
||||||
"LabelShowSubtitles": "Felirat megjelenítése",
|
"LabelShowSubtitles": "Felirat megjelenítése",
|
||||||
"LabelSize": "Méret",
|
"LabelSize": "Méret",
|
||||||
"LabelSleepTimer": "Alvásidőzítő",
|
"LabelSleepTimer": "Alvásidőzítő",
|
||||||
@ -596,8 +604,8 @@
|
|||||||
"LabelStartTime": "Kezdési idő",
|
"LabelStartTime": "Kezdési idő",
|
||||||
"LabelStarted": "Elkezdődött",
|
"LabelStarted": "Elkezdődött",
|
||||||
"LabelStartedAt": "Kezdés ideje",
|
"LabelStartedAt": "Kezdés ideje",
|
||||||
"LabelStatsAudioTracks": "Audiósávok",
|
"LabelStatsAudioTracks": "Audiósáv",
|
||||||
"LabelStatsAuthors": "Szerzők",
|
"LabelStatsAuthors": "Szerző",
|
||||||
"LabelStatsBestDay": "Legjobb nap",
|
"LabelStatsBestDay": "Legjobb nap",
|
||||||
"LabelStatsDailyAverage": "Napi átlag",
|
"LabelStatsDailyAverage": "Napi átlag",
|
||||||
"LabelStatsDays": "Napok",
|
"LabelStatsDays": "Napok",
|
||||||
@ -605,7 +613,7 @@
|
|||||||
"LabelStatsHours": "Órák",
|
"LabelStatsHours": "Órák",
|
||||||
"LabelStatsInARow": "egymás után",
|
"LabelStatsInARow": "egymás után",
|
||||||
"LabelStatsItemsFinished": "Befejezett elem",
|
"LabelStatsItemsFinished": "Befejezett elem",
|
||||||
"LabelStatsItemsInLibrary": "Elemek a könyvtárban",
|
"LabelStatsItemsInLibrary": "Elem a könyvtárban",
|
||||||
"LabelStatsMinutes": "perc",
|
"LabelStatsMinutes": "perc",
|
||||||
"LabelStatsMinutesListening": "Hallgatási perc",
|
"LabelStatsMinutesListening": "Hallgatási perc",
|
||||||
"LabelStatsOverallDays": "Összes nap",
|
"LabelStatsOverallDays": "Összes nap",
|
||||||
@ -684,8 +692,8 @@
|
|||||||
"LabelWeekdaysToRun": "Futás napjai",
|
"LabelWeekdaysToRun": "Futás napjai",
|
||||||
"LabelXBooks": "{0} könyv",
|
"LabelXBooks": "{0} könyv",
|
||||||
"LabelXItems": "{0} elem",
|
"LabelXItems": "{0} elem",
|
||||||
"LabelYearReviewHide": "Az évvisszatekintés elrejtése",
|
"LabelYearReviewHide": "Visszatekintés az évre elrejtése",
|
||||||
"LabelYearReviewShow": "Évvisszatekintés megtekintése",
|
"LabelYearReviewShow": "Visszatekintés az évre megtekintése",
|
||||||
"LabelYourAudiobookDuration": "Hangoskönyv időtartama",
|
"LabelYourAudiobookDuration": "Hangoskönyv időtartama",
|
||||||
"LabelYourBookmarks": "Könyvjelzőid",
|
"LabelYourBookmarks": "Könyvjelzőid",
|
||||||
"LabelYourPlaylists": "Lejátszási listáid",
|
"LabelYourPlaylists": "Lejátszási listáid",
|
||||||
@ -750,10 +758,12 @@
|
|||||||
"MessageConfirmResetProgress": "Biztos, hogy vissza akarja állítani a haladási folyamatát?",
|
"MessageConfirmResetProgress": "Biztos, hogy vissza akarja állítani a haladási folyamatát?",
|
||||||
"MessageConfirmSendEbookToDevice": "Biztosan el szeretné küldeni a(z) {0} e-könyvet a(z) \"{1}\" eszközre?",
|
"MessageConfirmSendEbookToDevice": "Biztosan el szeretné küldeni a(z) {0} e-könyvet a(z) \"{1}\" eszközre?",
|
||||||
"MessageConfirmUnlinkOpenId": "Biztos, hogy el akarja távolítani ezt a felhasználót az OpenID-ból?",
|
"MessageConfirmUnlinkOpenId": "Biztos, hogy el akarja távolítani ezt a felhasználót az OpenID-ból?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} napot hallgatott az elmúlt évben",
|
||||||
"MessageDownloadingEpisode": "Epizód letöltése",
|
"MessageDownloadingEpisode": "Epizód letöltése",
|
||||||
"MessageDragFilesIntoTrackOrder": "Húzza a fájlokat a helyes sávrendbe",
|
"MessageDragFilesIntoTrackOrder": "Húzza a fájlokat a helyes sávrendbe",
|
||||||
"MessageEmbedFailed": "A beágyazás sikertelen!",
|
"MessageEmbedFailed": "A beágyazás sikertelen!",
|
||||||
"MessageEmbedFinished": "Beágyazás befejeződött!",
|
"MessageEmbedFinished": "Beágyazás befejeződött!",
|
||||||
|
"MessageEmbedQueue": "Metaadatok beágyazására várakozik ({0} a sorban)",
|
||||||
"MessageEpisodesQueuedForDownload": "{0} epizód letöltésre vár",
|
"MessageEpisodesQueuedForDownload": "{0} epizód letöltésre vár",
|
||||||
"MessageEreaderDevices": "Az e-könyvek kézbesítésének biztosítása érdekében a fenti e-mail címet az alább felsorolt minden egyes eszközhöz, mint érvényes feladót kell hozzáadnia.",
|
"MessageEreaderDevices": "Az e-könyvek kézbesítésének biztosítása érdekében a fenti e-mail címet az alább felsorolt minden egyes eszközhöz, mint érvényes feladót kell hozzáadnia.",
|
||||||
"MessageFeedURLWillBe": "A hírcsatorna URL-je {0} lesz",
|
"MessageFeedURLWillBe": "A hírcsatorna URL-je {0} lesz",
|
||||||
@ -816,6 +826,7 @@
|
|||||||
"MessagePodcastHasNoRSSFeedForMatching": "A podcastnak nincs RSS hírcsatorna URL-je az egyeztetéshez",
|
"MessagePodcastHasNoRSSFeedForMatching": "A podcastnak nincs RSS hírcsatorna URL-je az egyeztetéshez",
|
||||||
"MessagePodcastSearchField": "Adja meg a keresési kifejezést vagy az RSS hírcsatorna URL-címét",
|
"MessagePodcastSearchField": "Adja meg a keresési kifejezést vagy az RSS hírcsatorna URL-címét",
|
||||||
"MessageQuickEmbedInProgress": "Gyors beágyazás folyamatban",
|
"MessageQuickEmbedInProgress": "Gyors beágyazás folyamatban",
|
||||||
|
"MessageQuickEmbedQueue": "Gyors beágyazásra várakozik ({0} a sorban)",
|
||||||
"MessageQuickMatchAllEpisodes": "Minden epizód gyors egyeztetése",
|
"MessageQuickMatchAllEpisodes": "Minden epizód gyors egyeztetése",
|
||||||
"MessageQuickMatchDescription": "Üres elem részletek és borító feltöltése az első találati eredménnyel a(z) '{0}'-ból. Nem írja felül a részleteket, kivéve, ha a 'Preferált egyeztetett metaadatok' szerverbeállítás engedélyezve van.",
|
"MessageQuickMatchDescription": "Üres elem részletek és borító feltöltése az első találati eredménnyel a(z) '{0}'-ból. Nem írja felül a részleteket, kivéve, ha a 'Preferált egyeztetett metaadatok' szerverbeállítás engedélyezve van.",
|
||||||
"MessageRemoveChapter": "Fejezet eltávolítása",
|
"MessageRemoveChapter": "Fejezet eltávolítása",
|
||||||
@ -826,12 +837,14 @@
|
|||||||
"MessageResetChaptersConfirm": "Biztosan alaphelyzetbe szeretné állítani a fejezeteket és visszavonni a módosításokat?",
|
"MessageResetChaptersConfirm": "Biztosan alaphelyzetbe szeretné állítani a fejezeteket és visszavonni a módosításokat?",
|
||||||
"MessageRestoreBackupConfirm": "Biztosan vissza szeretné állítani a biztonsági másolatot, amely ekkor készült:",
|
"MessageRestoreBackupConfirm": "Biztosan vissza szeretné állítani a biztonsági másolatot, amely ekkor készült:",
|
||||||
"MessageRestoreBackupWarning": "A biztonsági mentés visszaállítása felülírja az egész adatbázist, amely a /config mappában található, valamint a borítóképeket a /metadata/items és /metadata/authors mappákban.<br /><br />A biztonsági mentések nem módosítják a könyvtár mappáiban található fájlokat. Ha engedélyezte a szerverbeállításokat a borítóképek és a metaadatok könyvtármappákban való tárolására, akkor ezek nem kerülnek biztonsági mentésre vagy felülírásra.<br /><br />A szerver használó összes kliens automatikusan frissül.",
|
"MessageRestoreBackupWarning": "A biztonsági mentés visszaállítása felülírja az egész adatbázist, amely a /config mappában található, valamint a borítóképeket a /metadata/items és /metadata/authors mappákban.<br /><br />A biztonsági mentések nem módosítják a könyvtár mappáiban található fájlokat. Ha engedélyezte a szerverbeállításokat a borítóképek és a metaadatok könyvtármappákban való tárolására, akkor ezek nem kerülnek biztonsági mentésre vagy felülírásra.<br /><br />A szerver használó összes kliens automatikusan frissül.",
|
||||||
|
"MessageScheduleLibraryScanNote": "A legtöbb felhasználó számára ajánlott ezt a funkciót kikapcsolva hagyni, és engedélyezni a mappafigyelő beállítást. A mappafigyelő automatikusan észleli a könyvtári mappák változásait. A mappafigyelő nem működik minden fájlrendszernél (mint például az NFS), ezért helyette ütemezett könyvtárellenőrzéseket lehet használni.",
|
||||||
"MessageSearchResultsFor": "Keresési eredmények",
|
"MessageSearchResultsFor": "Keresési eredmények",
|
||||||
"MessageSelected": "{0} kiválasztva",
|
"MessageSelected": "{0} kiválasztva",
|
||||||
"MessageServerCouldNotBeReached": "A szervert nem lehet elérni",
|
"MessageServerCouldNotBeReached": "A szervert nem lehet elérni",
|
||||||
"MessageSetChaptersFromTracksDescription": "Fejezetek beállítása minden egyes hangfájlt egy fejezetként használva, és a fejezet címét a hangfájl neveként",
|
"MessageSetChaptersFromTracksDescription": "Fejezetek beállítása minden egyes hangfájlt egy fejezetként használva, és a fejezet címét a hangfájl neveként",
|
||||||
"MessageShareExpirationWillBe": "A lejárat: <strong>{0}</strong>",
|
"MessageShareExpirationWillBe": "A lejárat: <strong>{0}</strong>",
|
||||||
"MessageShareExpiresIn": "{0} múlva jár le",
|
"MessageShareExpiresIn": "{0} múlva jár le",
|
||||||
|
"MessageShareURLWillBe": "A megosztási URL <strong>{0}</strong> lesz",
|
||||||
"MessageStartPlaybackAtTime": "\"{0}\" lejátszásának kezdése {1} -tól?",
|
"MessageStartPlaybackAtTime": "\"{0}\" lejátszásának kezdése {1} -tól?",
|
||||||
"MessageTaskAudioFileNotWritable": "A/Az „{0}” hangfájl nem írható",
|
"MessageTaskAudioFileNotWritable": "A/Az „{0}” hangfájl nem írható",
|
||||||
"MessageTaskCanceledByUser": "Felhasználó törölte a feladatot",
|
"MessageTaskCanceledByUser": "Felhasználó törölte a feladatot",
|
||||||
@ -937,7 +950,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Könyvjelző létrehozása sikertelen",
|
"ToastBookmarkCreateFailed": "Könyvjelző létrehozása sikertelen",
|
||||||
"ToastBookmarkCreateSuccess": "Könyvjelző hozzáadva",
|
"ToastBookmarkCreateSuccess": "Könyvjelző hozzáadva",
|
||||||
"ToastBookmarkRemoveSuccess": "Könyvjelző eltávolítva",
|
"ToastBookmarkRemoveSuccess": "Könyvjelző eltávolítva",
|
||||||
"ToastBookmarkUpdateSuccess": "Könyvjelző frissítve",
|
|
||||||
"ToastCachePurgeFailed": "A gyorsítótár törlése sikertelen",
|
"ToastCachePurgeFailed": "A gyorsítótár törlése sikertelen",
|
||||||
"ToastCachePurgeSuccess": "A gyorsítótár sikeresen törölve",
|
"ToastCachePurgeSuccess": "A gyorsítótár sikeresen törölve",
|
||||||
"ToastChaptersHaveErrors": "A fejezetek hibákat tartalmaznak",
|
"ToastChaptersHaveErrors": "A fejezetek hibákat tartalmaznak",
|
||||||
@ -947,6 +959,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Gyűjtemény eltávolítva",
|
"ToastCollectionRemoveSuccess": "Gyűjtemény eltávolítva",
|
||||||
"ToastCollectionUpdateSuccess": "Gyűjtemény frissítve",
|
"ToastCollectionUpdateSuccess": "Gyűjtemény frissítve",
|
||||||
"ToastCoverUpdateFailed": "A borító frissítése nem sikerült",
|
"ToastCoverUpdateFailed": "A borító frissítése nem sikerült",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "A dátum és az időpont érvénytelen vagy hiányos",
|
||||||
"ToastDeleteFileFailed": "Nem sikerült törölni a fájlt",
|
"ToastDeleteFileFailed": "Nem sikerült törölni a fájlt",
|
||||||
"ToastDeleteFileSuccess": "Fájl törölve",
|
"ToastDeleteFileSuccess": "Fájl törölve",
|
||||||
"ToastDeviceAddFailed": "Nem sikerült eszközt hozzáadni",
|
"ToastDeviceAddFailed": "Nem sikerült eszközt hozzáadni",
|
||||||
@ -954,9 +967,11 @@
|
|||||||
"ToastDeviceTestEmailFailed": "Teszt email küldése sikertelen",
|
"ToastDeviceTestEmailFailed": "Teszt email küldése sikertelen",
|
||||||
"ToastDeviceTestEmailSuccess": "Teszt email elküldve",
|
"ToastDeviceTestEmailSuccess": "Teszt email elküldve",
|
||||||
"ToastEmailSettingsUpdateSuccess": "Email beállítások frissítve",
|
"ToastEmailSettingsUpdateSuccess": "Email beállítások frissítve",
|
||||||
|
"ToastEncodeCancelFailed": "A kódolás törlése sikertelen volt",
|
||||||
"ToastEncodeCancelSucces": "Kódolás törölve",
|
"ToastEncodeCancelSucces": "Kódolás törölve",
|
||||||
"ToastEpisodeDownloadQueueClearFailed": "Nem sikerült törölni a várólistát",
|
"ToastEpisodeDownloadQueueClearFailed": "Nem sikerült törölni a várólistát",
|
||||||
"ToastEpisodeUpdateSuccess": "{0} epizód frissítve",
|
"ToastEpisodeUpdateSuccess": "{0} epizód frissítve",
|
||||||
|
"ToastErrorCannotShare": "Ezen az eszközön nem lehet natívan megosztani",
|
||||||
"ToastFailedToLoadData": "Sikertelen adatbetöltés",
|
"ToastFailedToLoadData": "Sikertelen adatbetöltés",
|
||||||
"ToastFailedToMatch": "Nem sikerült egyezőséget találni",
|
"ToastFailedToMatch": "Nem sikerült egyezőséget találni",
|
||||||
"ToastFailedToShare": "Nem sikerült megosztani",
|
"ToastFailedToShare": "Nem sikerült megosztani",
|
||||||
@ -992,10 +1007,15 @@
|
|||||||
"ToastNewUserCreatedSuccess": "Új fiók létrehozva",
|
"ToastNewUserCreatedSuccess": "Új fiók létrehozva",
|
||||||
"ToastNewUserLibraryError": "Legalább egy könyvtárat ki kell választani",
|
"ToastNewUserLibraryError": "Legalább egy könyvtárat ki kell választani",
|
||||||
"ToastNewUserPasswordError": "Kötelező a jelszó, csak a root felhasználónak lehet üres jelszava",
|
"ToastNewUserPasswordError": "Kötelező a jelszó, csak a root felhasználónak lehet üres jelszava",
|
||||||
|
"ToastNewUserTagError": "Legalább egy címkét ki kell választania",
|
||||||
"ToastNewUserUsernameError": "Adjon meg egy felhasználónevet",
|
"ToastNewUserUsernameError": "Adjon meg egy felhasználónevet",
|
||||||
"ToastNoNewEpisodesFound": "Nincs új epizód",
|
"ToastNoNewEpisodesFound": "Nincs új epizód",
|
||||||
|
"ToastNoRSSFeed": "A podcastnak nincs RSS hírcsatornája",
|
||||||
"ToastNoUpdatesNecessary": "Nincs szükség frissítésre",
|
"ToastNoUpdatesNecessary": "Nincs szükség frissítésre",
|
||||||
|
"ToastNotificationCreateFailed": "Értesítés létrehozása sikertelen",
|
||||||
|
"ToastNotificationDeleteFailed": "Értesítés törlése sikertelen",
|
||||||
"ToastNotificationSettingsUpdateSuccess": "Értesítési beállítások frissítve",
|
"ToastNotificationSettingsUpdateSuccess": "Értesítési beállítások frissítve",
|
||||||
|
"ToastNotificationTestTriggerFailed": "Nem sikerült a tesztértesítést elindítani",
|
||||||
"ToastNotificationUpdateSuccess": "Értesítés frissítve",
|
"ToastNotificationUpdateSuccess": "Értesítés frissítve",
|
||||||
"ToastPlaylistCreateFailed": "Lejátszási lista létrehozása sikertelen",
|
"ToastPlaylistCreateFailed": "Lejátszási lista létrehozása sikertelen",
|
||||||
"ToastPlaylistCreateSuccess": "Lejátszási lista létrehozva",
|
"ToastPlaylistCreateSuccess": "Lejátszási lista létrehozva",
|
||||||
@ -1005,22 +1025,37 @@
|
|||||||
"ToastPodcastCreateSuccess": "A podcast sikeresen létrehozva",
|
"ToastPodcastCreateSuccess": "A podcast sikeresen létrehozva",
|
||||||
"ToastPodcastNoEpisodesInFeed": "Nincsenek epizódok az RSS hírcsatornában",
|
"ToastPodcastNoEpisodesInFeed": "Nincsenek epizódok az RSS hírcsatornában",
|
||||||
"ToastPodcastNoRssFeed": "A podcastnak nincs RSS-hírcsatornája",
|
"ToastPodcastNoRssFeed": "A podcastnak nincs RSS-hírcsatornája",
|
||||||
|
"ToastProgressIsNotBeingSynced": "Az előrehaladás nem szinkronizálódik, a lejátszás újraindul",
|
||||||
|
"ToastProviderCreatedFailed": "Hiba a szolgáltató hozzáadásakor",
|
||||||
|
"ToastProviderCreatedSuccess": "Új szolgáltató hozzáadva",
|
||||||
|
"ToastProviderNameAndUrlRequired": "Név és Url kötelező",
|
||||||
|
"ToastProviderRemoveSuccess": "Szolgáltató eltávolítva",
|
||||||
"ToastRSSFeedCloseFailed": "Az RSS hírcsatorna bezárása sikertelen",
|
"ToastRSSFeedCloseFailed": "Az RSS hírcsatorna bezárása sikertelen",
|
||||||
"ToastRSSFeedCloseSuccess": "RSS hírfolyam leállítva",
|
"ToastRSSFeedCloseSuccess": "RSS hírfolyam leállítva",
|
||||||
|
"ToastRemoveFailed": "Sikertelen eltávolítás",
|
||||||
"ToastRemoveItemFromCollectionFailed": "Tétel eltávolítása a gyűjteményből sikertelen",
|
"ToastRemoveItemFromCollectionFailed": "Tétel eltávolítása a gyűjteményből sikertelen",
|
||||||
"ToastRemoveItemFromCollectionSuccess": "Tétel eltávolítva a gyűjteményből",
|
"ToastRemoveItemFromCollectionSuccess": "Tétel eltávolítva a gyűjteményből",
|
||||||
|
"ToastRenameFailed": "Sikertelen átnevezés",
|
||||||
|
"ToastSelectAtLeastOneUser": "Válasszon legalább egy felhasználót",
|
||||||
"ToastSendEbookToDeviceFailed": "E-könyv küldése az eszközre sikertelen",
|
"ToastSendEbookToDeviceFailed": "E-könyv küldése az eszközre sikertelen",
|
||||||
"ToastSendEbookToDeviceSuccess": "E-könyv elküldve az eszközre \"{0}\"",
|
"ToastSendEbookToDeviceSuccess": "E-könyv elküldve az eszközre \"{0}\"",
|
||||||
"ToastSeriesUpdateFailed": "Sorozat frissítése sikertelen",
|
"ToastSeriesUpdateFailed": "Sorozat frissítése sikertelen",
|
||||||
"ToastSeriesUpdateSuccess": "Sorozat frissítése sikeres",
|
"ToastSeriesUpdateSuccess": "Sorozat frissítése sikeres",
|
||||||
|
"ToastServerSettingsUpdateSuccess": "Szerver beállítások frissítve",
|
||||||
|
"ToastSessionCloseFailed": "A munkamenet bezárása sikertelen",
|
||||||
"ToastSessionDeleteFailed": "Munkamenet törlése sikertelen",
|
"ToastSessionDeleteFailed": "Munkamenet törlése sikertelen",
|
||||||
"ToastSessionDeleteSuccess": "Munkamenet törölve",
|
"ToastSessionDeleteSuccess": "Munkamenet törölve",
|
||||||
|
"ToastSleepTimerDone": "Alvásidőzítő kész... zZzzZZz",
|
||||||
"ToastSocketConnected": "Socket csatlakoztatva",
|
"ToastSocketConnected": "Socket csatlakoztatva",
|
||||||
"ToastSocketDisconnected": "Socket lecsatlakoztatva",
|
"ToastSocketDisconnected": "Socket lecsatlakoztatva",
|
||||||
"ToastSocketFailedToConnect": "A Socket csatlakoztatása sikertelen",
|
"ToastSocketFailedToConnect": "A Socket csatlakoztatása sikertelen",
|
||||||
|
"ToastSortingPrefixesEmptyError": "Legalább 1 rendezési előtaggal kell rendelkeznie",
|
||||||
|
"ToastSortingPrefixesUpdateSuccess": "Rendezési előtagok frissítése ({0} elem)",
|
||||||
|
"ToastTitleRequired": "A cím kötelező",
|
||||||
"ToastUnknownError": "Ismeretlen hiba",
|
"ToastUnknownError": "Ismeretlen hiba",
|
||||||
"ToastUserDeleteFailed": "Felhasználó törlése sikertelen",
|
"ToastUserDeleteFailed": "Felhasználó törlése sikertelen",
|
||||||
"ToastUserDeleteSuccess": "Felhasználó törölve",
|
"ToastUserDeleteSuccess": "Felhasználó törölve",
|
||||||
"ToastUserPasswordChangeSuccess": "Jelszó sikeresen megváltoztatva",
|
"ToastUserPasswordChangeSuccess": "Jelszó sikeresen megváltoztatva",
|
||||||
|
"ToastUserPasswordMustChange": "Az új jelszó nem egyezik a régi jelszóval",
|
||||||
"ToastUserRootRequireName": "Egy root felhasználónevet kell megadnia"
|
"ToastUserRootRequireName": "Egy root felhasználónevet kell megadnia"
|
||||||
}
|
}
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
"ButtonNext": "Prossimo",
|
"ButtonNext": "Prossimo",
|
||||||
"ButtonNextChapter": "Prossimo Capitolo",
|
"ButtonNextChapter": "Prossimo Capitolo",
|
||||||
"ButtonNextItemInQueue": "Elemento successivo in coda",
|
"ButtonNextItemInQueue": "Elemento successivo in coda",
|
||||||
"ButtonOk": "D’accordo",
|
"ButtonOk": "D'accordo",
|
||||||
"ButtonOpenFeed": "Apri il flusso",
|
"ButtonOpenFeed": "Apri il flusso",
|
||||||
"ButtonOpenManager": "Apri Manager",
|
"ButtonOpenManager": "Apri Manager",
|
||||||
"ButtonPause": "Pausa",
|
"ButtonPause": "Pausa",
|
||||||
@ -941,7 +941,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Creazione segnalibro fallita",
|
"ToastBookmarkCreateFailed": "Creazione segnalibro fallita",
|
||||||
"ToastBookmarkCreateSuccess": "Segnalibro creato",
|
"ToastBookmarkCreateSuccess": "Segnalibro creato",
|
||||||
"ToastBookmarkRemoveSuccess": "Segnalibro Rimosso",
|
"ToastBookmarkRemoveSuccess": "Segnalibro Rimosso",
|
||||||
"ToastBookmarkUpdateSuccess": "Segnalibro aggiornato",
|
|
||||||
"ToastCachePurgeFailed": "Impossibile eliminare la cache",
|
"ToastCachePurgeFailed": "Impossibile eliminare la cache",
|
||||||
"ToastCachePurgeSuccess": "Cache eliminata correttamente",
|
"ToastCachePurgeSuccess": "Cache eliminata correttamente",
|
||||||
"ToastChaptersHaveErrors": "I capitoli contengono errori",
|
"ToastChaptersHaveErrors": "I capitoli contengono errori",
|
||||||
|
@ -660,7 +660,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Žymos sukurti nepavyko",
|
"ToastBookmarkCreateFailed": "Žymos sukurti nepavyko",
|
||||||
"ToastBookmarkCreateSuccess": "Žyma pridėta",
|
"ToastBookmarkCreateSuccess": "Žyma pridėta",
|
||||||
"ToastBookmarkRemoveSuccess": "Žyma pašalinta",
|
"ToastBookmarkRemoveSuccess": "Žyma pašalinta",
|
||||||
"ToastBookmarkUpdateSuccess": "Žyma atnaujinta",
|
|
||||||
"ToastChaptersHaveErrors": "Skyriai turi klaidų",
|
"ToastChaptersHaveErrors": "Skyriai turi klaidų",
|
||||||
"ToastChaptersMustHaveTitles": "Skyriai turi turėti pavadinimus",
|
"ToastChaptersMustHaveTitles": "Skyriai turi turėti pavadinimus",
|
||||||
"ToastChaptersRemoved": "Skyriai pašalinti",
|
"ToastChaptersRemoved": "Skyriai pašalinti",
|
||||||
|
@ -88,6 +88,8 @@
|
|||||||
"ButtonSaveTracklist": "Afspeellijst opslaan",
|
"ButtonSaveTracklist": "Afspeellijst opslaan",
|
||||||
"ButtonScan": "Scannen",
|
"ButtonScan": "Scannen",
|
||||||
"ButtonScanLibrary": "Scan bibliotheek",
|
"ButtonScanLibrary": "Scan bibliotheek",
|
||||||
|
"ButtonScrollLeft": "Scroll Links",
|
||||||
|
"ButtonScrollRight": "Scroll Rechts",
|
||||||
"ButtonSearch": "Zoeken",
|
"ButtonSearch": "Zoeken",
|
||||||
"ButtonSelectFolderPath": "Maplocatie selecteren",
|
"ButtonSelectFolderPath": "Maplocatie selecteren",
|
||||||
"ButtonSeries": "Series",
|
"ButtonSeries": "Series",
|
||||||
@ -153,7 +155,7 @@
|
|||||||
"HeaderLogs": "Logboek",
|
"HeaderLogs": "Logboek",
|
||||||
"HeaderManageGenres": "Genres beheren",
|
"HeaderManageGenres": "Genres beheren",
|
||||||
"HeaderManageTags": "Tags beheren",
|
"HeaderManageTags": "Tags beheren",
|
||||||
"HeaderMapDetails": "Map details",
|
"HeaderMapDetails": "Details map",
|
||||||
"HeaderMatch": "Vergelijken",
|
"HeaderMatch": "Vergelijken",
|
||||||
"HeaderMetadataOrderOfPrecedence": "Metadata volgorde",
|
"HeaderMetadataOrderOfPrecedence": "Metadata volgorde",
|
||||||
"HeaderMetadataToEmbed": "In te sluiten metadata",
|
"HeaderMetadataToEmbed": "In te sluiten metadata",
|
||||||
@ -190,6 +192,7 @@
|
|||||||
"HeaderSettingsExperimental": "Experimentele functies",
|
"HeaderSettingsExperimental": "Experimentele functies",
|
||||||
"HeaderSettingsGeneral": "Algemeen",
|
"HeaderSettingsGeneral": "Algemeen",
|
||||||
"HeaderSettingsScanner": "Scanner",
|
"HeaderSettingsScanner": "Scanner",
|
||||||
|
"HeaderSettingsWebClient": "Web Client",
|
||||||
"HeaderSleepTimer": "Slaaptimer",
|
"HeaderSleepTimer": "Slaaptimer",
|
||||||
"HeaderStatsLargestItems": "Grootste items",
|
"HeaderStatsLargestItems": "Grootste items",
|
||||||
"HeaderStatsLongestItems": "Langste items (uren)",
|
"HeaderStatsLongestItems": "Langste items (uren)",
|
||||||
@ -297,6 +300,7 @@
|
|||||||
"LabelDiscover": "Ontdekken",
|
"LabelDiscover": "Ontdekken",
|
||||||
"LabelDownload": "Download",
|
"LabelDownload": "Download",
|
||||||
"LabelDownloadNEpisodes": "Download {0} afleveringen",
|
"LabelDownloadNEpisodes": "Download {0} afleveringen",
|
||||||
|
"LabelDownloadable": "Downloadbaar",
|
||||||
"LabelDuration": "Duur",
|
"LabelDuration": "Duur",
|
||||||
"LabelDurationComparisonExactMatch": "(exacte overeenkomst)",
|
"LabelDurationComparisonExactMatch": "(exacte overeenkomst)",
|
||||||
"LabelDurationComparisonLonger": "({0} langer)",
|
"LabelDurationComparisonLonger": "({0} langer)",
|
||||||
@ -472,6 +476,7 @@
|
|||||||
"LabelPermissionsAccessAllLibraries": "Heeft toegang tot all bibliotheken",
|
"LabelPermissionsAccessAllLibraries": "Heeft toegang tot all bibliotheken",
|
||||||
"LabelPermissionsAccessAllTags": "Heeft toegang tot alle tags",
|
"LabelPermissionsAccessAllTags": "Heeft toegang tot alle tags",
|
||||||
"LabelPermissionsAccessExplicitContent": "Heeft toegang tot expliciete inhoud",
|
"LabelPermissionsAccessExplicitContent": "Heeft toegang tot expliciete inhoud",
|
||||||
|
"LabelPermissionsCreateEreader": "Kan Ereader Aanmaken",
|
||||||
"LabelPermissionsDelete": "Kan verwijderen",
|
"LabelPermissionsDelete": "Kan verwijderen",
|
||||||
"LabelPermissionsDownload": "Kan downloaden",
|
"LabelPermissionsDownload": "Kan downloaden",
|
||||||
"LabelPermissionsUpdate": "Kan bijwerken",
|
"LabelPermissionsUpdate": "Kan bijwerken",
|
||||||
@ -541,6 +546,7 @@
|
|||||||
"LabelServerYearReview": "Server Jaar in Review ({0})",
|
"LabelServerYearReview": "Server Jaar in Review ({0})",
|
||||||
"LabelSetEbookAsPrimary": "Stel in als primair",
|
"LabelSetEbookAsPrimary": "Stel in als primair",
|
||||||
"LabelSetEbookAsSupplementary": "Stel in als supplementair",
|
"LabelSetEbookAsSupplementary": "Stel in als supplementair",
|
||||||
|
"LabelSettingsAllowIframe": "Insluiten in iframe toestaan",
|
||||||
"LabelSettingsAudiobooksOnly": "Alleen audiobooks",
|
"LabelSettingsAudiobooksOnly": "Alleen audiobooks",
|
||||||
"LabelSettingsAudiobooksOnlyHelp": "Deze instelling inschakelen zorgt ervoor dat ebook-bestanden genegeerd worden tenzij ze in een audiobook-map staan, in welk geval ze worden ingesteld als supplementaire ebooks",
|
"LabelSettingsAudiobooksOnlyHelp": "Deze instelling inschakelen zorgt ervoor dat ebook-bestanden genegeerd worden tenzij ze in een audiobook-map staan, in welk geval ze worden ingesteld als supplementaire ebooks",
|
||||||
"LabelSettingsBookshelfViewHelp": "Skeumorphisch design met houten planken",
|
"LabelSettingsBookshelfViewHelp": "Skeumorphisch design met houten planken",
|
||||||
@ -562,6 +568,9 @@
|
|||||||
"LabelSettingsHideSingleBookSeriesHelp": "Series die slechts een enkel boek bevatten worden verborgen op de seriespagina en de homepagina-planken.",
|
"LabelSettingsHideSingleBookSeriesHelp": "Series die slechts een enkel boek bevatten worden verborgen op de seriespagina en de homepagina-planken.",
|
||||||
"LabelSettingsHomePageBookshelfView": "Boekenplank-view voor homepagina",
|
"LabelSettingsHomePageBookshelfView": "Boekenplank-view voor homepagina",
|
||||||
"LabelSettingsLibraryBookshelfView": "Boekenplank-view voor bibliotheek",
|
"LabelSettingsLibraryBookshelfView": "Boekenplank-view voor bibliotheek",
|
||||||
|
"LabelSettingsLibraryMarkAsFinishedPercentComplete": "Voltooid percentage is groter dan",
|
||||||
|
"LabelSettingsLibraryMarkAsFinishedTimeRemaining": "Resterende tijd is kleiner dan (seconden)",
|
||||||
|
"LabelSettingsLibraryMarkAsFinishedWhen": "Markeer media item wanneer voltooid",
|
||||||
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Sla eedere boeken in Serie Verderzetten over",
|
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Sla eedere boeken in Serie Verderzetten over",
|
||||||
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "De Continue Series home page shelf toont het eerste boek dat nog niet is begonnen in series waarvan er minstens één is voltooid en er geen boeken in uitvoering zijn. Als u deze instelling inschakelt, wordt de serie voortgezet vanaf het boek dat het verst is voltooid in plaats van het eerste boek dat nog niet is begonnen.",
|
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "De Continue Series home page shelf toont het eerste boek dat nog niet is begonnen in series waarvan er minstens één is voltooid en er geen boeken in uitvoering zijn. Als u deze instelling inschakelt, wordt de serie voortgezet vanaf het boek dat het verst is voltooid in plaats van het eerste boek dat nog niet is begonnen.",
|
||||||
"LabelSettingsParseSubtitles": "Parseer subtitel",
|
"LabelSettingsParseSubtitles": "Parseer subtitel",
|
||||||
@ -580,6 +589,7 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "Standaard worden metadata-bestanden bewaard in /metadata/items, door deze instelling in te schakelen zullen metadata bestanden in de map van je bibliotheekonderdeel bewaard worden",
|
"LabelSettingsStoreMetadataWithItemHelp": "Standaard worden metadata-bestanden bewaard in /metadata/items, door deze instelling in te schakelen zullen metadata bestanden in de map van je bibliotheekonderdeel bewaard worden",
|
||||||
"LabelSettingsTimeFormat": "Tijdformat",
|
"LabelSettingsTimeFormat": "Tijdformat",
|
||||||
"LabelShare": "Delen",
|
"LabelShare": "Delen",
|
||||||
|
"LabelShareDownloadableHelp": "Gebruikers toestaan met share link om zip bestand te downloaden van het bibliotheek item.",
|
||||||
"LabelShareOpen": "Delen Open",
|
"LabelShareOpen": "Delen Open",
|
||||||
"LabelShareURL": "URL Delen",
|
"LabelShareURL": "URL Delen",
|
||||||
"LabelShowAll": "Toon alle",
|
"LabelShowAll": "Toon alle",
|
||||||
@ -588,6 +598,8 @@
|
|||||||
"LabelSize": "Grootte",
|
"LabelSize": "Grootte",
|
||||||
"LabelSleepTimer": "Slaaptimer",
|
"LabelSleepTimer": "Slaaptimer",
|
||||||
"LabelSlug": "Slak",
|
"LabelSlug": "Slak",
|
||||||
|
"LabelSortAscending": "Oplopend",
|
||||||
|
"LabelSortDescending": "Aflopend",
|
||||||
"LabelStart": "Start",
|
"LabelStart": "Start",
|
||||||
"LabelStartTime": "Starttijd",
|
"LabelStartTime": "Starttijd",
|
||||||
"LabelStarted": "Gestart",
|
"LabelStarted": "Gestart",
|
||||||
@ -659,6 +671,7 @@
|
|||||||
"LabelUpdateDetailsHelp": "Sta overschrijven van bestaande details toe voor de geselecteerde boeken wanneer een match is gevonden",
|
"LabelUpdateDetailsHelp": "Sta overschrijven van bestaande details toe voor de geselecteerde boeken wanneer een match is gevonden",
|
||||||
"LabelUpdatedAt": "Bijgewerkt op",
|
"LabelUpdatedAt": "Bijgewerkt op",
|
||||||
"LabelUploaderDragAndDrop": "Slepen & neerzeten van bestanden of mappen",
|
"LabelUploaderDragAndDrop": "Slepen & neerzeten van bestanden of mappen",
|
||||||
|
"LabelUploaderDragAndDropFilesOnly": "Drag & drop bestanden",
|
||||||
"LabelUploaderDropFiles": "Bestanden neerzetten",
|
"LabelUploaderDropFiles": "Bestanden neerzetten",
|
||||||
"LabelUploaderItemFetchMetadataHelp": "Automatisch titel, auteur en serie ophalen",
|
"LabelUploaderItemFetchMetadataHelp": "Automatisch titel, auteur en serie ophalen",
|
||||||
"LabelUseAdvancedOptions": "Gebruik Geavanceerde Instellingen",
|
"LabelUseAdvancedOptions": "Gebruik Geavanceerde Instellingen",
|
||||||
@ -674,6 +687,8 @@
|
|||||||
"LabelViewPlayerSettings": "Laat spelerinstellingen zien",
|
"LabelViewPlayerSettings": "Laat spelerinstellingen zien",
|
||||||
"LabelViewQueue": "Bekijk afspeelwachtrij",
|
"LabelViewQueue": "Bekijk afspeelwachtrij",
|
||||||
"LabelVolume": "Volume",
|
"LabelVolume": "Volume",
|
||||||
|
"LabelWebRedirectURLsDescription": "Autoriseer deze URL's in uw OAuth-provider om na het inloggen omleiding terug naar de web-app toe te staan:",
|
||||||
|
"LabelWebRedirectURLsSubfolder": "Subfolder voor Redirect URLs",
|
||||||
"LabelWeekdaysToRun": "Weekdagen om te draaien",
|
"LabelWeekdaysToRun": "Weekdagen om te draaien",
|
||||||
"LabelXBooks": "{0} boeken",
|
"LabelXBooks": "{0} boeken",
|
||||||
"LabelXItems": "{0} items",
|
"LabelXItems": "{0} items",
|
||||||
@ -743,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "Bet u zeker dat u uw voortgang wil resetten?",
|
"MessageConfirmResetProgress": "Bet u zeker dat u uw voortgang wil resetten?",
|
||||||
"MessageConfirmSendEbookToDevice": "Weet je zeker dat je {0} ebook \"{1}\" naar apparaat \"{2}\" wil sturen?",
|
"MessageConfirmSendEbookToDevice": "Weet je zeker dat je {0} ebook \"{1}\" naar apparaat \"{2}\" wil sturen?",
|
||||||
"MessageConfirmUnlinkOpenId": "Bent u zeker dat u deze gebruiker wil ontkoppelen van OpenID?",
|
"MessageConfirmUnlinkOpenId": "Bent u zeker dat u deze gebruiker wil ontkoppelen van OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} dagen geluisterd in het voorbije jaar",
|
||||||
"MessageDownloadingEpisode": "Aflevering aan het dowloaden",
|
"MessageDownloadingEpisode": "Aflevering aan het dowloaden",
|
||||||
"MessageDragFilesIntoTrackOrder": "Sleep bestanden in de juiste trackvolgorde",
|
"MessageDragFilesIntoTrackOrder": "Sleep bestanden in de juiste trackvolgorde",
|
||||||
"MessageEmbedFailed": "Insluiten Mislukt!",
|
"MessageEmbedFailed": "Insluiten Mislukt!",
|
||||||
@ -821,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "Weet je zeker dat je de hoofdstukken wil resetten en de wijzigingen die je gemaakt hebt ongedaan wil maken?",
|
"MessageResetChaptersConfirm": "Weet je zeker dat je de hoofdstukken wil resetten en de wijzigingen die je gemaakt hebt ongedaan wil maken?",
|
||||||
"MessageRestoreBackupConfirm": "Weet je zeker dat je wil herstellen met behulp van de back-up gemaakt op",
|
"MessageRestoreBackupConfirm": "Weet je zeker dat je wil herstellen met behulp van de back-up gemaakt op",
|
||||||
"MessageRestoreBackupWarning": "Herstellen met een back-up zal de volledige database in /config en de covers in /metadata/items & /metadata/authors overschrijven.<br /><br />Back-ups wijzigen geen bestanden in je bibliotheekmappen. Als je de serverinstelling gebruikt om covers en metadata in je bibliotheekmappen te bewaren dan worden deze niet geback-upt of overschreven.<br /><br />Alle clients die van je server gebruik maken zullen automatisch worden ververst.",
|
"MessageRestoreBackupWarning": "Herstellen met een back-up zal de volledige database in /config en de covers in /metadata/items & /metadata/authors overschrijven.<br /><br />Back-ups wijzigen geen bestanden in je bibliotheekmappen. Als je de serverinstelling gebruikt om covers en metadata in je bibliotheekmappen te bewaren dan worden deze niet geback-upt of overschreven.<br /><br />Alle clients die van je server gebruik maken zullen automatisch worden ververst.",
|
||||||
|
"MessageScheduleLibraryScanNote": "Voor de meeste gebruikers is het raadzaam om deze functie uitgeschakeld te laten en de folder watcher-instelling ingeschakeld te houden. De folder watcher detecteert automatisch wijzigingen in uw bibliotheekmappen. De folder watcher werkt niet voor elk bestandssysteem (zoals NFS), dus geplande bibliotheekscans kunnen in plaats daarvan worden gebruikt.",
|
||||||
"MessageSearchResultsFor": "Zoekresultaten voor",
|
"MessageSearchResultsFor": "Zoekresultaten voor",
|
||||||
"MessageSelected": "{0} geselecteerd",
|
"MessageSelected": "{0} geselecteerd",
|
||||||
"MessageServerCouldNotBeReached": "Server niet bereikbaar",
|
"MessageServerCouldNotBeReached": "Server niet bereikbaar",
|
||||||
@ -937,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Aanmaken boekwijzer mislukt",
|
"ToastBookmarkCreateFailed": "Aanmaken boekwijzer mislukt",
|
||||||
"ToastBookmarkCreateSuccess": "boekwijzer toegevoegd",
|
"ToastBookmarkCreateSuccess": "boekwijzer toegevoegd",
|
||||||
"ToastBookmarkRemoveSuccess": "Boekwijzer verwijderd",
|
"ToastBookmarkRemoveSuccess": "Boekwijzer verwijderd",
|
||||||
"ToastBookmarkUpdateSuccess": "Boekwijzer bijgewerkt",
|
|
||||||
"ToastCachePurgeFailed": "Cache wissen is mislukt",
|
"ToastCachePurgeFailed": "Cache wissen is mislukt",
|
||||||
"ToastCachePurgeSuccess": "Cache succesvol verwijderd",
|
"ToastCachePurgeSuccess": "Cache succesvol verwijderd",
|
||||||
"ToastChaptersHaveErrors": "Hoofdstukken bevatten fouten",
|
"ToastChaptersHaveErrors": "Hoofdstukken bevatten fouten",
|
||||||
@ -948,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Collectie verwijderd",
|
"ToastCollectionRemoveSuccess": "Collectie verwijderd",
|
||||||
"ToastCollectionUpdateSuccess": "Collectie bijgewerkt",
|
"ToastCollectionUpdateSuccess": "Collectie bijgewerkt",
|
||||||
"ToastCoverUpdateFailed": "Cover update mislukt",
|
"ToastCoverUpdateFailed": "Cover update mislukt",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Datum en tijd ongeldig of onvolledig",
|
||||||
"ToastDeleteFileFailed": "Bestand verwijderen mislukt",
|
"ToastDeleteFileFailed": "Bestand verwijderen mislukt",
|
||||||
"ToastDeleteFileSuccess": "Bestand verwijderd",
|
"ToastDeleteFileSuccess": "Bestand verwijderd",
|
||||||
"ToastDeviceAddFailed": "Apparaat toevoegen mislukt",
|
"ToastDeviceAddFailed": "Apparaat toevoegen mislukt",
|
||||||
@ -1000,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Moet ten minste een tag selecteren",
|
"ToastNewUserTagError": "Moet ten minste een tag selecteren",
|
||||||
"ToastNewUserUsernameError": "Voer een gebruikersnaam in",
|
"ToastNewUserUsernameError": "Voer een gebruikersnaam in",
|
||||||
"ToastNoNewEpisodesFound": "Geen nieuwe afleveringen gevonden",
|
"ToastNoNewEpisodesFound": "Geen nieuwe afleveringen gevonden",
|
||||||
|
"ToastNoRSSFeed": "Podcast heeft geen RSS Feed",
|
||||||
"ToastNoUpdatesNecessary": "Geen updates nodig",
|
"ToastNoUpdatesNecessary": "Geen updates nodig",
|
||||||
"ToastNotificationCreateFailed": "Nieuwe melding aanmaken mislukt",
|
"ToastNotificationCreateFailed": "Nieuwe melding aanmaken mislukt",
|
||||||
"ToastNotificationDeleteFailed": "Melding verwijderen mislukt",
|
"ToastNotificationDeleteFailed": "Melding verwijderen mislukt",
|
||||||
|
@ -12,7 +12,7 @@
|
|||||||
"ButtonBack": "Tilbake",
|
"ButtonBack": "Tilbake",
|
||||||
"ButtonBrowseForFolder": "Bla gjennom mappe",
|
"ButtonBrowseForFolder": "Bla gjennom mappe",
|
||||||
"ButtonCancel": "Avbryt",
|
"ButtonCancel": "Avbryt",
|
||||||
"ButtonCancelEncode": "Avbryt Encode",
|
"ButtonCancelEncode": "Avbryt konvertering",
|
||||||
"ButtonChangeRootPassword": "Bytt Root-bruker passord",
|
"ButtonChangeRootPassword": "Bytt Root-bruker passord",
|
||||||
"ButtonCheckAndDownloadNewEpisodes": "Sjekk og last ned nye episoder",
|
"ButtonCheckAndDownloadNewEpisodes": "Sjekk og last ned nye episoder",
|
||||||
"ButtonChooseAFolder": "Velg mappe",
|
"ButtonChooseAFolder": "Velg mappe",
|
||||||
@ -97,10 +97,10 @@
|
|||||||
"ButtonShare": "Del",
|
"ButtonShare": "Del",
|
||||||
"ButtonShiftTimes": "Forskyv tider",
|
"ButtonShiftTimes": "Forskyv tider",
|
||||||
"ButtonShow": "Vis",
|
"ButtonShow": "Vis",
|
||||||
"ButtonStartM4BEncode": "Start M4B Koding",
|
"ButtonStartM4BEncode": "Start konvertering til M4B",
|
||||||
"ButtonStartMetadataEmbed": "Start Metadata innbaking",
|
"ButtonStartMetadataEmbed": "Start Metadata innbaking",
|
||||||
"ButtonStats": "Statistikk",
|
"ButtonStats": "Statistikk",
|
||||||
"ButtonSubmit": "Send inn",
|
"ButtonSubmit": "Lagre",
|
||||||
"ButtonTest": "Test",
|
"ButtonTest": "Test",
|
||||||
"ButtonUnlinkOpenId": "Koble fra OpenID",
|
"ButtonUnlinkOpenId": "Koble fra OpenID",
|
||||||
"ButtonUpload": "Last opp",
|
"ButtonUpload": "Last opp",
|
||||||
@ -143,12 +143,12 @@
|
|||||||
"HeaderFindChapters": "Finn Kapittel",
|
"HeaderFindChapters": "Finn Kapittel",
|
||||||
"HeaderIgnoredFiles": "Ignorerte filer",
|
"HeaderIgnoredFiles": "Ignorerte filer",
|
||||||
"HeaderItemFiles": "Elementfiler",
|
"HeaderItemFiles": "Elementfiler",
|
||||||
"HeaderItemMetadataUtils": "Enhet Metadata verktøy",
|
"HeaderItemMetadataUtils": "Element Metadata verktøy",
|
||||||
"HeaderLastListeningSession": "Siste lyttesesjon",
|
"HeaderLastListeningSession": "Siste lyttesesjon",
|
||||||
"HeaderLatestEpisodes": "Siste episoder",
|
"HeaderLatestEpisodes": "Siste episoder",
|
||||||
"HeaderLibraries": "Biblioteker",
|
"HeaderLibraries": "Biblioteker",
|
||||||
"HeaderLibraryFiles": "Bibliotek filer",
|
"HeaderLibraryFiles": "Bibliotek filer",
|
||||||
"HeaderLibraryStats": "Bibliotek statistikk",
|
"HeaderLibraryStats": "Bibliotekstatistikk",
|
||||||
"HeaderListeningSessions": "Lyttesesjoner",
|
"HeaderListeningSessions": "Lyttesesjoner",
|
||||||
"HeaderListeningStats": "Lyttestatistikk",
|
"HeaderListeningStats": "Lyttestatistikk",
|
||||||
"HeaderLogin": "Logg inn",
|
"HeaderLogin": "Logg inn",
|
||||||
@ -300,6 +300,7 @@
|
|||||||
"LabelDiscover": "Oppdag",
|
"LabelDiscover": "Oppdag",
|
||||||
"LabelDownload": "Last ned",
|
"LabelDownload": "Last ned",
|
||||||
"LabelDownloadNEpisodes": "Last ned {0} episoder",
|
"LabelDownloadNEpisodes": "Last ned {0} episoder",
|
||||||
|
"LabelDownloadable": "Nedlastbar",
|
||||||
"LabelDuration": "Varighet",
|
"LabelDuration": "Varighet",
|
||||||
"LabelDurationComparisonExactMatch": "(nøyaktig treff)",
|
"LabelDurationComparisonExactMatch": "(nøyaktig treff)",
|
||||||
"LabelDurationComparisonLonger": "({0} lenger)",
|
"LabelDurationComparisonLonger": "({0} lenger)",
|
||||||
@ -365,11 +366,11 @@
|
|||||||
"LabelFormat": "Format",
|
"LabelFormat": "Format",
|
||||||
"LabelFull": "Full",
|
"LabelFull": "Full",
|
||||||
"LabelGenre": "Sjanger",
|
"LabelGenre": "Sjanger",
|
||||||
"LabelGenres": "Sjangers",
|
"LabelGenres": "Sjangre",
|
||||||
"LabelHardDeleteFile": "Tving sletting av fil",
|
"LabelHardDeleteFile": "Tving sletting av fil",
|
||||||
"LabelHasEbook": "Har e-bok",
|
"LabelHasEbook": "Har e-bok",
|
||||||
"LabelHasSupplementaryEbook": "Har komplimentær e-bok",
|
"LabelHasSupplementaryEbook": "Har komplimentær e-bok",
|
||||||
"LabelHideSubtitles": "Skjul undertekster",
|
"LabelHideSubtitles": "Skjul undertitler",
|
||||||
"LabelHighestPriority": "Høyeste prioritet",
|
"LabelHighestPriority": "Høyeste prioritet",
|
||||||
"LabelHost": "Tjener",
|
"LabelHost": "Tjener",
|
||||||
"LabelHour": "Time",
|
"LabelHour": "Time",
|
||||||
@ -406,7 +407,7 @@
|
|||||||
"LabelLess": "Mindre",
|
"LabelLess": "Mindre",
|
||||||
"LabelLibrariesAccessibleToUser": "Biblioteker tilgjengelig for bruker",
|
"LabelLibrariesAccessibleToUser": "Biblioteker tilgjengelig for bruker",
|
||||||
"LabelLibrary": "Bibliotek",
|
"LabelLibrary": "Bibliotek",
|
||||||
"LabelLibraryFilterSublistEmpty": "",
|
"LabelLibraryFilterSublistEmpty": "Ingen {0}",
|
||||||
"LabelLibraryItem": "Bibliotek enhet",
|
"LabelLibraryItem": "Bibliotek enhet",
|
||||||
"LabelLibraryName": "Bibliotek navn",
|
"LabelLibraryName": "Bibliotek navn",
|
||||||
"LabelLimit": "Begrensning",
|
"LabelLimit": "Begrensning",
|
||||||
@ -570,7 +571,7 @@
|
|||||||
"LabelSettingsLibraryMarkAsFinishedWhen": "Marker som ferdig når",
|
"LabelSettingsLibraryMarkAsFinishedWhen": "Marker som ferdig når",
|
||||||
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Hopp over tidligere bøker i \"Fortsett serien\"",
|
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Hopp over tidligere bøker i \"Fortsett serien\"",
|
||||||
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "\"Fortsett serie\"-siden viser første bok som ikke er påbegynt i serier der en bok er lest og ingen bøker leses nå. Ved å slå på denne innstillingen så vil man fortsette på serien etter siste leste bok, fremfor første bok som ikke er startet på i en serie.",
|
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "\"Fortsett serie\"-siden viser første bok som ikke er påbegynt i serier der en bok er lest og ingen bøker leses nå. Ved å slå på denne innstillingen så vil man fortsette på serien etter siste leste bok, fremfor første bok som ikke er startet på i en serie.",
|
||||||
"LabelSettingsParseSubtitles": "Analyser undertekster",
|
"LabelSettingsParseSubtitles": "Analyser undertitler",
|
||||||
"LabelSettingsParseSubtitlesHelp": "Hent undertittel fra lydbokens mappenavn.<br>Undertittel må være separert med \" - \"<br>f.eks. \"Boktittel - En lengre tittel\" har undertittel \"En lengre tittel\".",
|
"LabelSettingsParseSubtitlesHelp": "Hent undertittel fra lydbokens mappenavn.<br>Undertittel må være separert med \" - \"<br>f.eks. \"Boktittel - En lengre tittel\" har undertittel \"En lengre tittel\".",
|
||||||
"LabelSettingsPreferMatchedMetadata": "Foretrekk funnet metadata",
|
"LabelSettingsPreferMatchedMetadata": "Foretrekk funnet metadata",
|
||||||
"LabelSettingsPreferMatchedMetadataHelp": "Funnet data vil overskrive enhetens detaljene når man bruker Kjapt søk. Som standard vil Kjapt søk kun fylle inn manglende detaljer.",
|
"LabelSettingsPreferMatchedMetadataHelp": "Funnet data vil overskrive enhetens detaljene når man bruker Kjapt søk. Som standard vil Kjapt søk kun fylle inn manglende detaljer.",
|
||||||
@ -586,6 +587,7 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "Som standard vil metadata bli lagret under /metadata/items, aktiveres dette valget vil metadata bli lagret i samme mappe som gjenstanden",
|
"LabelSettingsStoreMetadataWithItemHelp": "Som standard vil metadata bli lagret under /metadata/items, aktiveres dette valget vil metadata bli lagret i samme mappe som gjenstanden",
|
||||||
"LabelSettingsTimeFormat": "Tid format",
|
"LabelSettingsTimeFormat": "Tid format",
|
||||||
"LabelShare": "Dele",
|
"LabelShare": "Dele",
|
||||||
|
"LabelShareDownloadableHelp": "Tillat brukere med en delt link å laste ned en zip-fil av elementet.",
|
||||||
"LabelShareOpen": "Åpne deling",
|
"LabelShareOpen": "Åpne deling",
|
||||||
"LabelShareURL": "Dele URL",
|
"LabelShareURL": "Dele URL",
|
||||||
"LabelShowAll": "Vis alle",
|
"LabelShowAll": "Vis alle",
|
||||||
@ -615,7 +617,7 @@
|
|||||||
"LabelStatsOverallDays": "Totale dager",
|
"LabelStatsOverallDays": "Totale dager",
|
||||||
"LabelStatsOverallHours": "Totale timer",
|
"LabelStatsOverallHours": "Totale timer",
|
||||||
"LabelStatsWeekListening": "Uker lyttet",
|
"LabelStatsWeekListening": "Uker lyttet",
|
||||||
"LabelSubtitle": "undertekster",
|
"LabelSubtitle": "Undertittel",
|
||||||
"LabelSupportedFileTypes": "Støttede filtyper",
|
"LabelSupportedFileTypes": "Støttede filtyper",
|
||||||
"LabelTag": "Tag",
|
"LabelTag": "Tag",
|
||||||
"LabelTags": "Tagger",
|
"LabelTags": "Tagger",
|
||||||
@ -640,11 +642,11 @@
|
|||||||
"LabelTimeRemaining": "{0} gjennstående",
|
"LabelTimeRemaining": "{0} gjennstående",
|
||||||
"LabelTimeToShift": "Tid å forflytte i sekunder",
|
"LabelTimeToShift": "Tid å forflytte i sekunder",
|
||||||
"LabelTitle": "Tittel",
|
"LabelTitle": "Tittel",
|
||||||
"LabelToolsEmbedMetadata": "Bak inn metadata",
|
"LabelToolsEmbedMetadata": "Bygg inn metadata",
|
||||||
"LabelToolsEmbedMetadataDescription": "Bak inn metadata i lydfilen, inkludert omslagsbilde og kapitler.",
|
"LabelToolsEmbedMetadataDescription": "Bak inn metadata i lydfilen, inkludert omslagsbilde og kapitler.",
|
||||||
"LabelToolsM4bEncoder": "M4B enkoder",
|
"LabelToolsM4bEncoder": "M4B enkoder",
|
||||||
"LabelToolsMakeM4b": "Lag M4B Lydbokfil",
|
"LabelToolsMakeM4b": "Lag M4B Lydbokfil",
|
||||||
"LabelToolsMakeM4bDescription": "Lager en.M4B lydbokfil med innbakte omslagsbilde og kapitler.",
|
"LabelToolsMakeM4bDescription": "Lager en M4B lydbokfil med innbakt omslagsbilde og kapitler.",
|
||||||
"LabelToolsSplitM4b": "Del M4B inn i MP3er",
|
"LabelToolsSplitM4b": "Del M4B inn i MP3er",
|
||||||
"LabelToolsSplitM4bDescription": "Lager MP3er fra en M4B inndelt i kapitler med innbakt metadata, omslagsbilde og kapitler.",
|
"LabelToolsSplitM4bDescription": "Lager MP3er fra en M4B inndelt i kapitler med innbakt metadata, omslagsbilde og kapitler.",
|
||||||
"LabelTotalDuration": "Total lengde",
|
"LabelTotalDuration": "Total lengde",
|
||||||
@ -754,6 +756,7 @@
|
|||||||
"MessageConfirmResetProgress": "Er du sikkert på at du vil tilbakestille fremgangen?",
|
"MessageConfirmResetProgress": "Er du sikkert på at du vil tilbakestille fremgangen?",
|
||||||
"MessageConfirmSendEbookToDevice": "Er du sikker på at du vil sende {0} ebok \"{1}\" til enhet \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "Er du sikker på at du vil sende {0} ebok \"{1}\" til enhet \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "Er du sikker på at du vil koble denne brukeren fra OpenID?",
|
"MessageConfirmUnlinkOpenId": "Er du sikker på at du vil koble denne brukeren fra OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} dager med lytting siste året",
|
||||||
"MessageDownloadingEpisode": "Laster ned episode",
|
"MessageDownloadingEpisode": "Laster ned episode",
|
||||||
"MessageDragFilesIntoTrackOrder": "Dra filene i rett spor rekkefølge",
|
"MessageDragFilesIntoTrackOrder": "Dra filene i rett spor rekkefølge",
|
||||||
"MessageEmbedFailed": "Innbygging feilet!",
|
"MessageEmbedFailed": "Innbygging feilet!",
|
||||||
@ -771,6 +774,7 @@
|
|||||||
"MessageJoinUsOn": "Følg oss nå",
|
"MessageJoinUsOn": "Følg oss nå",
|
||||||
"MessageLoading": "Laster...",
|
"MessageLoading": "Laster...",
|
||||||
"MessageLoadingFolders": "Laster mapper...",
|
"MessageLoadingFolders": "Laster mapper...",
|
||||||
|
"MessageLogsDescription": "Logger lagres i <code>/metadata/logs</code> som JSON-filer. Krasjlogger lagres i <code>/metadata/logs/crash_logs.txt</code>.",
|
||||||
"MessageM4BFailed": "M4B mislykkes!",
|
"MessageM4BFailed": "M4B mislykkes!",
|
||||||
"MessageM4BFinished": "M4B fullført!",
|
"MessageM4BFinished": "M4B fullført!",
|
||||||
"MessageMapChapterTitles": "Bruk kapittel titler fra din eksisterende lydbok kapitler uten å justere tidsstempel",
|
"MessageMapChapterTitles": "Bruk kapittel titler fra din eksisterende lydbok kapitler uten å justere tidsstempel",
|
||||||
@ -787,6 +791,7 @@
|
|||||||
"MessageNoCollections": "Ingen samlinger",
|
"MessageNoCollections": "Ingen samlinger",
|
||||||
"MessageNoCoversFound": "Ingen omslagsbilde funnet",
|
"MessageNoCoversFound": "Ingen omslagsbilde funnet",
|
||||||
"MessageNoDescription": "Ingen beskrivelse",
|
"MessageNoDescription": "Ingen beskrivelse",
|
||||||
|
"MessageNoDevices": "Ingen enheter",
|
||||||
"MessageNoDownloadsInProgress": "Ingen aktive nedlastinger",
|
"MessageNoDownloadsInProgress": "Ingen aktive nedlastinger",
|
||||||
"MessageNoDownloadsQueued": "Ingen nedlastinger i kø",
|
"MessageNoDownloadsQueued": "Ingen nedlastinger i kø",
|
||||||
"MessageNoEpisodeMatchesFound": "Ingen lik episode funnet",
|
"MessageNoEpisodeMatchesFound": "Ingen lik episode funnet",
|
||||||
@ -800,6 +805,7 @@
|
|||||||
"MessageNoLogs": "Ingen logger",
|
"MessageNoLogs": "Ingen logger",
|
||||||
"MessageNoMediaProgress": "Ingen mediefremgang",
|
"MessageNoMediaProgress": "Ingen mediefremgang",
|
||||||
"MessageNoNotifications": "Ingen varslinger",
|
"MessageNoNotifications": "Ingen varslinger",
|
||||||
|
"MessageNoPodcastFeed": "Ugyldig podcast: Ingen feed",
|
||||||
"MessageNoPodcastsFound": "Ingen podcaster funnet",
|
"MessageNoPodcastsFound": "Ingen podcaster funnet",
|
||||||
"MessageNoResults": "Ingen resultat",
|
"MessageNoResults": "Ingen resultat",
|
||||||
"MessageNoSearchResultsFor": "Ingen søkeresultat for \"{0}\"",
|
"MessageNoSearchResultsFor": "Ingen søkeresultat for \"{0}\"",
|
||||||
@ -809,11 +815,17 @@
|
|||||||
"MessageNoUpdatesWereNecessary": "Ingen oppdatering var nødvendig",
|
"MessageNoUpdatesWereNecessary": "Ingen oppdatering var nødvendig",
|
||||||
"MessageNoUserPlaylists": "Du har ingen spillelister",
|
"MessageNoUserPlaylists": "Du har ingen spillelister",
|
||||||
"MessageNotYetImplemented": "Ikke implementert ennå",
|
"MessageNotYetImplemented": "Ikke implementert ennå",
|
||||||
|
"MessageOpmlPreviewNote": "PS: Dette er en forhåndvisning av en OPML-fil. Den faktiske podcast-tittelen hentes direkte fra RSS-feeden.",
|
||||||
"MessageOr": "eller",
|
"MessageOr": "eller",
|
||||||
"MessagePauseChapter": "Pause avspilling av kapittel",
|
"MessagePauseChapter": "Pause avspilling av kapittel",
|
||||||
"MessagePlayChapter": "Lytter på begynnelsen av kapittel",
|
"MessagePlayChapter": "Lytter på begynnelsen av kapittel",
|
||||||
"MessagePlaylistCreateFromCollection": "Lag spilleliste fra samling",
|
"MessagePlaylistCreateFromCollection": "Lag spilleliste fra samling",
|
||||||
|
"MessagePleaseWait": "Vennligst vent...",
|
||||||
"MessagePodcastHasNoRSSFeedForMatching": "Podcast har ingen RSS feed url til bruk av sammenligning",
|
"MessagePodcastHasNoRSSFeedForMatching": "Podcast har ingen RSS feed url til bruk av sammenligning",
|
||||||
|
"MessagePodcastSearchField": "Skriv inn søkeord eller RSS-feed URL",
|
||||||
|
"MessageQuickEmbedInProgress": "Hurtiginnbygging pågår",
|
||||||
|
"MessageQuickEmbedQueue": "Kø for hurtiginnbygging ({0} i kø)",
|
||||||
|
"MessageQuickMatchAllEpisodes": "Kjapp matching av alle episoder",
|
||||||
"MessageQuickMatchDescription": "Fyll inn tomme gjenstandsdetaljer og omslagsbilde med første resultat fra '{0}'. Overskriver ikke detaljene utenom 'Foretrekk funnet metadata' tjenerinstilling er aktivert.",
|
"MessageQuickMatchDescription": "Fyll inn tomme gjenstandsdetaljer og omslagsbilde med første resultat fra '{0}'. Overskriver ikke detaljene utenom 'Foretrekk funnet metadata' tjenerinstilling er aktivert.",
|
||||||
"MessageRemoveChapter": "fjerne kapittel",
|
"MessageRemoveChapter": "fjerne kapittel",
|
||||||
"MessageRemoveEpisodes": "fjerne {0} kapitler",
|
"MessageRemoveEpisodes": "fjerne {0} kapitler",
|
||||||
@ -823,10 +835,29 @@
|
|||||||
"MessageResetChaptersConfirm": "Er du sikker på at du vil nullstille kapitler og angre endringene du har gjort?",
|
"MessageResetChaptersConfirm": "Er du sikker på at du vil nullstille kapitler og angre endringene du har gjort?",
|
||||||
"MessageRestoreBackupConfirm": "Er du sikker på at du vil gjenopprette sikkerhetskopien som var laget",
|
"MessageRestoreBackupConfirm": "Er du sikker på at du vil gjenopprette sikkerhetskopien som var laget",
|
||||||
"MessageRestoreBackupWarning": "gjenoppretting av sikkerhetskopi vil overskrive hele databasen under /config og omslagsbilde under /metadata/items og /metadata/authors.<br /><br />Sikkerhetskopier endrer ikke noen filer under dine bibliotekmapper. Hvis du har aktivert tjenerinstillingen for å lagre omslagsbilder og metadata i bibliotekmapper så vil ikke de filene bli tatt sikkerhetskopi eller overskrevet.<br /><br />Alle klientene som bruker din tjener vil bli fornyet automatisk.",
|
"MessageRestoreBackupWarning": "gjenoppretting av sikkerhetskopi vil overskrive hele databasen under /config og omslagsbilde under /metadata/items og /metadata/authors.<br /><br />Sikkerhetskopier endrer ikke noen filer under dine bibliotekmapper. Hvis du har aktivert tjenerinstillingen for å lagre omslagsbilder og metadata i bibliotekmapper så vil ikke de filene bli tatt sikkerhetskopi eller overskrevet.<br /><br />Alle klientene som bruker din tjener vil bli fornyet automatisk.",
|
||||||
|
"MessageScheduleLibraryScanNote": "For de fleste brukere er det anbefalt å la denne funksjonen være slått av, og la mappeovervåkeren stå på. Mappeovervåkeren oppdager automatisk endringer i biblioteksmappene. Mappeovervåkeren fungerer ikke med alle filsystemer (f.eks. NFS) og da kan planlagt skanning av bibliotekene brukes i steden for.",
|
||||||
"MessageSearchResultsFor": "Søk resultat for",
|
"MessageSearchResultsFor": "Søk resultat for",
|
||||||
|
"MessageSelected": "{0} valgt",
|
||||||
"MessageServerCouldNotBeReached": "Tjener kunne ikke bli nådd",
|
"MessageServerCouldNotBeReached": "Tjener kunne ikke bli nådd",
|
||||||
"MessageSetChaptersFromTracksDescription": "Sett kapitler ved å bruke hver lydfil som kapittel og kapitteltittel som lydfilnavnet",
|
"MessageSetChaptersFromTracksDescription": "Sett kapitler ved å bruke hver lydfil som kapittel og kapitteltittel som lydfilnavnet",
|
||||||
|
"MessageShareExpirationWillBe": "Utløp vil være <strong>{0}</strong>",
|
||||||
|
"MessageShareExpiresIn": "Utløper om {0}",
|
||||||
|
"MessageShareURLWillBe": "URL for deling blir <strong>{0}</strong>",
|
||||||
"MessageStartPlaybackAtTime": "Start avspilling av \"{0}\" ved {1}?",
|
"MessageStartPlaybackAtTime": "Start avspilling av \"{0}\" ved {1}?",
|
||||||
|
"MessageTaskAudioFileNotWritable": "Lydfilen \"{0}\" kan ikke skrives til",
|
||||||
|
"MessageTaskCanceledByUser": "Oppgave kansellert av bruker",
|
||||||
|
"MessageTaskDownloadingEpisodeDescription": "Laster ned episode \"{0}\"",
|
||||||
|
"MessageTaskEmbeddingMetadata": "Bygger inn metadata",
|
||||||
|
"MessageTaskEmbeddingMetadataDescription": "Bygger inn metadata i lydboken \"{0}\"",
|
||||||
|
"MessageTaskEncodingM4b": "Konverterer til M4B",
|
||||||
|
"MessageTaskEncodingM4bDescription": "Konverterer lydboken \"{0}\" til én M4B-fil",
|
||||||
|
"MessageTaskFailed": "Feilet",
|
||||||
|
"MessageTaskFailedToBackupAudioFile": "Feil ved sikkerhetskopiering av lydfilen \"{0}\"",
|
||||||
|
"MessageTaskFailedToCreateCacheDirectory": "Kunne ikke opprette mappe for mellomlagring (cache)",
|
||||||
|
"MessageTaskFailedToEmbedMetadataInFile": "Kunne ikke bygge inn metadata i filen \"{0}\"",
|
||||||
|
"MessageTaskFailedToMergeAudioFiles": "Kunne ikke slå sammen lydfiler",
|
||||||
|
"MessageTaskFailedToMoveM4bFile": "Kunne ikke flytte M4B-fil",
|
||||||
|
"MessageTaskFailedToWriteMetadataFile": "Kunne ikke lagre metadata-fil",
|
||||||
"MessageThinking": "Tenker...",
|
"MessageThinking": "Tenker...",
|
||||||
"MessageUploaderItemFailed": "Opplastning mislykkes",
|
"MessageUploaderItemFailed": "Opplastning mislykkes",
|
||||||
"MessageUploaderItemSuccess": "Opplastning fullført!",
|
"MessageUploaderItemSuccess": "Opplastning fullført!",
|
||||||
@ -873,7 +904,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Misslykkes å opprette bokmerke",
|
"ToastBookmarkCreateFailed": "Misslykkes å opprette bokmerke",
|
||||||
"ToastBookmarkCreateSuccess": "Bokmerke lagt til",
|
"ToastBookmarkCreateSuccess": "Bokmerke lagt til",
|
||||||
"ToastBookmarkRemoveSuccess": "Bokmerke fjernet",
|
"ToastBookmarkRemoveSuccess": "Bokmerke fjernet",
|
||||||
"ToastBookmarkUpdateSuccess": "Bokmerke oppdatert",
|
|
||||||
"ToastCachePurgeFailed": "Kunne ikke å slette mellomlager",
|
"ToastCachePurgeFailed": "Kunne ikke å slette mellomlager",
|
||||||
"ToastCachePurgeSuccess": "Mellomlager slettet",
|
"ToastCachePurgeSuccess": "Mellomlager slettet",
|
||||||
"ToastChaptersHaveErrors": "Kapittel har feil",
|
"ToastChaptersHaveErrors": "Kapittel har feil",
|
||||||
|
@ -30,6 +30,7 @@
|
|||||||
"ButtonEditChapters": "Edytuj rozdziały",
|
"ButtonEditChapters": "Edytuj rozdziały",
|
||||||
"ButtonEditPodcast": "Edytuj podcast",
|
"ButtonEditPodcast": "Edytuj podcast",
|
||||||
"ButtonEnable": "Włącz",
|
"ButtonEnable": "Włącz",
|
||||||
|
"ButtonFireAndFail": "Fail start",
|
||||||
"ButtonForceReScan": "Wymuś ponowne skanowanie",
|
"ButtonForceReScan": "Wymuś ponowne skanowanie",
|
||||||
"ButtonFullPath": "Pełna ścieżka",
|
"ButtonFullPath": "Pełna ścieżka",
|
||||||
"ButtonHide": "Ukryj",
|
"ButtonHide": "Ukryj",
|
||||||
@ -770,7 +771,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Nie udało się utworzyć zakładki",
|
"ToastBookmarkCreateFailed": "Nie udało się utworzyć zakładki",
|
||||||
"ToastBookmarkCreateSuccess": "Dodano zakładkę",
|
"ToastBookmarkCreateSuccess": "Dodano zakładkę",
|
||||||
"ToastBookmarkRemoveSuccess": "Zakładka została usunięta",
|
"ToastBookmarkRemoveSuccess": "Zakładka została usunięta",
|
||||||
"ToastBookmarkUpdateSuccess": "Zaktualizowano zakładkę",
|
|
||||||
"ToastCollectionRemoveSuccess": "Kolekcja usunięta",
|
"ToastCollectionRemoveSuccess": "Kolekcja usunięta",
|
||||||
"ToastCollectionUpdateSuccess": "Zaktualizowano kolekcję",
|
"ToastCollectionUpdateSuccess": "Zaktualizowano kolekcję",
|
||||||
"ToastItemCoverUpdateSuccess": "Zaktualizowano okładkę",
|
"ToastItemCoverUpdateSuccess": "Zaktualizowano okładkę",
|
||||||
|
@ -729,7 +729,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Falha ao criar marcador",
|
"ToastBookmarkCreateFailed": "Falha ao criar marcador",
|
||||||
"ToastBookmarkCreateSuccess": "Marcador adicionado",
|
"ToastBookmarkCreateSuccess": "Marcador adicionado",
|
||||||
"ToastBookmarkRemoveSuccess": "Marcador removido",
|
"ToastBookmarkRemoveSuccess": "Marcador removido",
|
||||||
"ToastBookmarkUpdateSuccess": "Marcador atualizado",
|
|
||||||
"ToastCachePurgeFailed": "Falha ao apagar o cache",
|
"ToastCachePurgeFailed": "Falha ao apagar o cache",
|
||||||
"ToastCachePurgeSuccess": "Cache apagado com sucesso",
|
"ToastCachePurgeSuccess": "Cache apagado com sucesso",
|
||||||
"ToastChaptersHaveErrors": "Capítulos com erro",
|
"ToastChaptersHaveErrors": "Capítulos com erro",
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
"ButtonNext": "Следующий",
|
"ButtonNext": "Следующий",
|
||||||
"ButtonNextChapter": "Следующая глава",
|
"ButtonNextChapter": "Следующая глава",
|
||||||
"ButtonNextItemInQueue": "Следующий элемент в очереди",
|
"ButtonNextItemInQueue": "Следующий элемент в очереди",
|
||||||
"ButtonOk": "Ok",
|
"ButtonOk": "Ок",
|
||||||
"ButtonOpenFeed": "Открыть канал",
|
"ButtonOpenFeed": "Открыть канал",
|
||||||
"ButtonOpenManager": "Открыть менеджер",
|
"ButtonOpenManager": "Открыть менеджер",
|
||||||
"ButtonPause": "Пауза",
|
"ButtonPause": "Пауза",
|
||||||
@ -348,7 +348,7 @@
|
|||||||
"LabelFetchingMetadata": "Извлечение метаданных",
|
"LabelFetchingMetadata": "Извлечение метаданных",
|
||||||
"LabelFile": "Файл",
|
"LabelFile": "Файл",
|
||||||
"LabelFileBirthtime": "Дата создания",
|
"LabelFileBirthtime": "Дата создания",
|
||||||
"LabelFileBornDate": "Родился {0}",
|
"LabelFileBornDate": "Создан {0}",
|
||||||
"LabelFileModified": "Дата модификации",
|
"LabelFileModified": "Дата модификации",
|
||||||
"LabelFileModifiedDate": "Изменено {0}",
|
"LabelFileModifiedDate": "Изменено {0}",
|
||||||
"LabelFilename": "Имя файла",
|
"LabelFilename": "Имя файла",
|
||||||
@ -758,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "Вы уверены, что хотите сбросить свой прогресс?",
|
"MessageConfirmResetProgress": "Вы уверены, что хотите сбросить свой прогресс?",
|
||||||
"MessageConfirmSendEbookToDevice": "Вы уверены, что хотите отправить {0} e-книгу \"{1}\" на устройство \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "Вы уверены, что хотите отправить {0} e-книгу \"{1}\" на устройство \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "Вы уверены, что хотите отвязать этого пользователя от OpenID?",
|
"MessageConfirmUnlinkOpenId": "Вы уверены, что хотите отвязать этого пользователя от OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} дней прослушивания за последний год",
|
||||||
"MessageDownloadingEpisode": "Эпизод скачивается",
|
"MessageDownloadingEpisode": "Эпизод скачивается",
|
||||||
"MessageDragFilesIntoTrackOrder": "Перетащите файлы для исправления порядка треков",
|
"MessageDragFilesIntoTrackOrder": "Перетащите файлы для исправления порядка треков",
|
||||||
"MessageEmbedFailed": "Вставка не удалась!",
|
"MessageEmbedFailed": "Вставка не удалась!",
|
||||||
@ -836,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "Вы уверены, что хотите сбросить главы и отменить внесенные изменения?",
|
"MessageResetChaptersConfirm": "Вы уверены, что хотите сбросить главы и отменить внесенные изменения?",
|
||||||
"MessageRestoreBackupConfirm": "Вы уверены, что хотите восстановить резервную копию, созданную",
|
"MessageRestoreBackupConfirm": "Вы уверены, что хотите восстановить резервную копию, созданную",
|
||||||
"MessageRestoreBackupWarning": "Восстановление резервной копии перезапишет всю базу данных, расположенную в /config, и обложки изображений в /metadata/items и /metadata/authors.<br/><br/>Бэкапы не изменяют файлы в папках библиотеки. Если вы включили параметры сервера для хранения обложек и метаданных в папках библиотеки, то они не резервируются и не перезаписываются.<br/><br/>Все клиенты, использующие ваш сервер, будут автоматически обновлены.",
|
"MessageRestoreBackupWarning": "Восстановление резервной копии перезапишет всю базу данных, расположенную в /config, и обложки изображений в /metadata/items и /metadata/authors.<br/><br/>Бэкапы не изменяют файлы в папках библиотеки. Если вы включили параметры сервера для хранения обложек и метаданных в папках библиотеки, то они не резервируются и не перезаписываются.<br/><br/>Все клиенты, использующие ваш сервер, будут автоматически обновлены.",
|
||||||
|
"MessageScheduleLibraryScanNote": "Большинству пользователей рекомендуется отключить эту функцию и включить функцию просмотра папок. Программа просмотра папок автоматически обнаружит изменения в папках вашей библиотеки. Программа просмотра папок работает не для каждой файловой системы (например, NFS), поэтому вместо этого можно использовать запланированные проверки библиотеки.",
|
||||||
"MessageSearchResultsFor": "Результаты поиска для",
|
"MessageSearchResultsFor": "Результаты поиска для",
|
||||||
"MessageSelected": "{0} выбрано",
|
"MessageSelected": "{0} выбрано",
|
||||||
"MessageServerCouldNotBeReached": "Не удалось связаться с сервером",
|
"MessageServerCouldNotBeReached": "Не удалось связаться с сервером",
|
||||||
@ -952,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Не удалось создать закладку",
|
"ToastBookmarkCreateFailed": "Не удалось создать закладку",
|
||||||
"ToastBookmarkCreateSuccess": "Добавлена закладка",
|
"ToastBookmarkCreateSuccess": "Добавлена закладка",
|
||||||
"ToastBookmarkRemoveSuccess": "Закладка удалена",
|
"ToastBookmarkRemoveSuccess": "Закладка удалена",
|
||||||
"ToastBookmarkUpdateSuccess": "Закладка обновлена",
|
|
||||||
"ToastCachePurgeFailed": "Не удалось очистить кэш",
|
"ToastCachePurgeFailed": "Не удалось очистить кэш",
|
||||||
"ToastCachePurgeSuccess": "Кэш успешно очищен",
|
"ToastCachePurgeSuccess": "Кэш успешно очищен",
|
||||||
"ToastChaptersHaveErrors": "Главы имеют ошибки",
|
"ToastChaptersHaveErrors": "Главы имеют ошибки",
|
||||||
@ -963,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Коллекция удалена",
|
"ToastCollectionRemoveSuccess": "Коллекция удалена",
|
||||||
"ToastCollectionUpdateSuccess": "Коллекция обновлена",
|
"ToastCollectionUpdateSuccess": "Коллекция обновлена",
|
||||||
"ToastCoverUpdateFailed": "Не удалось обновить обложку",
|
"ToastCoverUpdateFailed": "Не удалось обновить обложку",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Дата и время указаны неверно или не до конца",
|
||||||
"ToastDeleteFileFailed": "Не удалось удалить файл",
|
"ToastDeleteFileFailed": "Не удалось удалить файл",
|
||||||
"ToastDeleteFileSuccess": "Файл удален",
|
"ToastDeleteFileSuccess": "Файл удален",
|
||||||
"ToastDeviceAddFailed": "Не удалось добавить устройство",
|
"ToastDeviceAddFailed": "Не удалось добавить устройство",
|
||||||
@ -1015,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Необходимо выбрать хотя бы один тег",
|
"ToastNewUserTagError": "Необходимо выбрать хотя бы один тег",
|
||||||
"ToastNewUserUsernameError": "Введите имя пользователя",
|
"ToastNewUserUsernameError": "Введите имя пользователя",
|
||||||
"ToastNoNewEpisodesFound": "Новых эпизодов не найдено",
|
"ToastNoNewEpisodesFound": "Новых эпизодов не найдено",
|
||||||
|
"ToastNoRSSFeed": "У подкаста нет RSS-канала",
|
||||||
"ToastNoUpdatesNecessary": "Обновления не требуются",
|
"ToastNoUpdatesNecessary": "Обновления не требуются",
|
||||||
"ToastNotificationCreateFailed": "Не удалось создать уведомление",
|
"ToastNotificationCreateFailed": "Не удалось создать уведомление",
|
||||||
"ToastNotificationDeleteFailed": "Не удалось удалить уведомление",
|
"ToastNotificationDeleteFailed": "Не удалось удалить уведомление",
|
||||||
|
@ -463,7 +463,7 @@
|
|||||||
"LabelNotificationsMaxQueueSize": "Največja velikost čakalne vrste za dogodke obvestil",
|
"LabelNotificationsMaxQueueSize": "Največja velikost čakalne vrste za dogodke obvestil",
|
||||||
"LabelNotificationsMaxQueueSizeHelp": "Dogodki so omejeni na sprožitev 1 na sekundo. Dogodki bodo prezrti, če je čakalna vrsta najvišja. To preprečuje neželeno pošiljanje obvestil.",
|
"LabelNotificationsMaxQueueSizeHelp": "Dogodki so omejeni na sprožitev 1 na sekundo. Dogodki bodo prezrti, če je čakalna vrsta najvišja. To preprečuje neželeno pošiljanje obvestil.",
|
||||||
"LabelNumberOfBooks": "Število knjig",
|
"LabelNumberOfBooks": "Število knjig",
|
||||||
"LabelNumberOfEpisodes": "število epizod",
|
"LabelNumberOfEpisodes": "# epizod",
|
||||||
"LabelOpenIDAdvancedPermsClaimDescription": "Ime zahtevka OpenID, ki vsebuje napredna dovoljenja za uporabniška dejanja v aplikaciji, ki bodo veljala za neskrbniške vloge (<b>če je konfigurirano</b>). Če trditev manjka v odgovoru, bo dostop do ABS zavrnjen. Če ena možnost manjka, bo obravnavana kot <code>false</code>. Zagotovite, da se zahtevek ponudnika identitete ujema s pričakovano strukturo:",
|
"LabelOpenIDAdvancedPermsClaimDescription": "Ime zahtevka OpenID, ki vsebuje napredna dovoljenja za uporabniška dejanja v aplikaciji, ki bodo veljala za neskrbniške vloge (<b>če je konfigurirano</b>). Če trditev manjka v odgovoru, bo dostop do ABS zavrnjen. Če ena možnost manjka, bo obravnavana kot <code>false</code>. Zagotovite, da se zahtevek ponudnika identitete ujema s pričakovano strukturo:",
|
||||||
"LabelOpenIDClaims": "Pustite naslednje možnosti prazne, da onemogočite napredno dodeljevanje skupin in dovoljenj, nato pa samodejno dodelite skupino 'Uporabnik'.",
|
"LabelOpenIDClaims": "Pustite naslednje možnosti prazne, da onemogočite napredno dodeljevanje skupin in dovoljenj, nato pa samodejno dodelite skupino 'Uporabnik'.",
|
||||||
"LabelOpenIDGroupClaimDescription": "Ime zahtevka OpenID, ki vsebuje seznam uporabnikovih skupin. Običajno imenovane <code>skupine</code>. <b>Če je konfigurirana</b>, bo aplikacija samodejno dodelila vloge na podlagi članstva v skupini uporabnika, pod pogojem, da so te skupine v zahtevku poimenovane 'admin', 'user' ali 'guest' brez razlikovanja med velikimi in malimi črkami. Zahtevek mora vsebovati seznam in če uporabnik pripada več skupinam, mu aplikacija dodeli vlogo, ki ustreza najvišjemu nivoju dostopa. Če se nobena skupina ne ujema, bo dostop zavrnjen.",
|
"LabelOpenIDGroupClaimDescription": "Ime zahtevka OpenID, ki vsebuje seznam uporabnikovih skupin. Običajno imenovane <code>skupine</code>. <b>Če je konfigurirana</b>, bo aplikacija samodejno dodelila vloge na podlagi članstva v skupini uporabnika, pod pogojem, da so te skupine v zahtevku poimenovane 'admin', 'user' ali 'guest' brez razlikovanja med velikimi in malimi črkami. Zahtevek mora vsebovati seznam in če uporabnik pripada več skupinam, mu aplikacija dodeli vlogo, ki ustreza najvišjemu nivoju dostopa. Če se nobena skupina ne ujema, bo dostop zavrnjen.",
|
||||||
@ -758,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "Ali ste prepričani, da želite ponastaviti svoj napredek?",
|
"MessageConfirmResetProgress": "Ali ste prepričani, da želite ponastaviti svoj napredek?",
|
||||||
"MessageConfirmSendEbookToDevice": "Ali ste prepričani, da želite poslati {0} e-knjigo \"{1}\" v napravo \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "Ali ste prepričani, da želite poslati {0} e-knjigo \"{1}\" v napravo \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "Ali ste prepričani, da želite prekiniti povezavo tega uporabnika z OpenID?",
|
"MessageConfirmUnlinkOpenId": "Ali ste prepričani, da želite prekiniti povezavo tega uporabnika z OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} dni poslušanja v zadnjem letu",
|
||||||
"MessageDownloadingEpisode": "Prenašam epizodo",
|
"MessageDownloadingEpisode": "Prenašam epizodo",
|
||||||
"MessageDragFilesIntoTrackOrder": "Povlecite datoteke v pravilen vrstni red posnetkov",
|
"MessageDragFilesIntoTrackOrder": "Povlecite datoteke v pravilen vrstni red posnetkov",
|
||||||
"MessageEmbedFailed": "Vdelava ni uspela!",
|
"MessageEmbedFailed": "Vdelava ni uspela!",
|
||||||
@ -836,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "Ali ste prepričani, da želite ponastaviti poglavja in razveljaviti spremembe, ki ste jih naredili?",
|
"MessageResetChaptersConfirm": "Ali ste prepričani, da želite ponastaviti poglavja in razveljaviti spremembe, ki ste jih naredili?",
|
||||||
"MessageRestoreBackupConfirm": "Ali ste prepričani, da želite obnoviti varnostno kopijo, ustvarjeno ob",
|
"MessageRestoreBackupConfirm": "Ali ste prepričani, da želite obnoviti varnostno kopijo, ustvarjeno ob",
|
||||||
"MessageRestoreBackupWarning": "Obnovitev varnostne kopije bo prepisala celotno zbirko podatkov, ki se nahaja v /config, in zajema slike v /metadata/items in /metadata/authors.<br /><br />Varnostne kopije ne spreminjajo nobenih datotek v mapah vaše knjižnice. Če ste omogočili nastavitve strežnika za shranjevanje naslovnic in metapodatkov v mapah vaše knjižnice, potem ti niso varnostno kopirani ali prepisani.<br /><br />Vsi odjemalci, ki uporabljajo vaš strežnik, bodo samodejno osveženi.",
|
"MessageRestoreBackupWarning": "Obnovitev varnostne kopije bo prepisala celotno zbirko podatkov, ki se nahaja v /config, in zajema slike v /metadata/items in /metadata/authors.<br /><br />Varnostne kopije ne spreminjajo nobenih datotek v mapah vaše knjižnice. Če ste omogočili nastavitve strežnika za shranjevanje naslovnic in metapodatkov v mapah vaše knjižnice, potem ti niso varnostno kopirani ali prepisani.<br /><br />Vsi odjemalci, ki uporabljajo vaš strežnik, bodo samodejno osveženi.",
|
||||||
|
"MessageScheduleLibraryScanNote": "Za večino uporabnikov je priporočljivo, da to funkcijo pustite onemogočeno in ohranite nastavitev pregledovalnika map omogočeno. Pregledovalnik map bo samodejno zaznal spremembe v mapah vaše knjižnice. Pregledovalnik map ne deluje za vse datotečne sisteme (na primer NFS), zato lahko namesto tega uporabite načrtovane preglede knjižnic.",
|
||||||
"MessageSearchResultsFor": "Rezultati iskanja za",
|
"MessageSearchResultsFor": "Rezultati iskanja za",
|
||||||
"MessageSelected": "{0} izbrano",
|
"MessageSelected": "{0} izbrano",
|
||||||
"MessageServerCouldNotBeReached": "Strežnika ni bilo mogoče doseči",
|
"MessageServerCouldNotBeReached": "Strežnika ni bilo mogoče doseči",
|
||||||
@ -952,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Zaznamka ni bilo mogoče ustvariti",
|
"ToastBookmarkCreateFailed": "Zaznamka ni bilo mogoče ustvariti",
|
||||||
"ToastBookmarkCreateSuccess": "Zaznamek dodan",
|
"ToastBookmarkCreateSuccess": "Zaznamek dodan",
|
||||||
"ToastBookmarkRemoveSuccess": "Zaznamek odstranjen",
|
"ToastBookmarkRemoveSuccess": "Zaznamek odstranjen",
|
||||||
"ToastBookmarkUpdateSuccess": "Zaznamek posodobljen",
|
|
||||||
"ToastCachePurgeFailed": "Čiščenje predpomnilnika ni uspelo",
|
"ToastCachePurgeFailed": "Čiščenje predpomnilnika ni uspelo",
|
||||||
"ToastCachePurgeSuccess": "Predpomnilnik je bil uspešno očiščen",
|
"ToastCachePurgeSuccess": "Predpomnilnik je bil uspešno očiščen",
|
||||||
"ToastChaptersHaveErrors": "Poglavja imajo napake",
|
"ToastChaptersHaveErrors": "Poglavja imajo napake",
|
||||||
@ -963,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Zbirka je bila odstranjena",
|
"ToastCollectionRemoveSuccess": "Zbirka je bila odstranjena",
|
||||||
"ToastCollectionUpdateSuccess": "Zbirka je bila posodobljena",
|
"ToastCollectionUpdateSuccess": "Zbirka je bila posodobljena",
|
||||||
"ToastCoverUpdateFailed": "Posodobitev naslovnice ni uspela",
|
"ToastCoverUpdateFailed": "Posodobitev naslovnice ni uspela",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Datum in čas sta neveljavna ali nepopolna",
|
||||||
"ToastDeleteFileFailed": "Brisanje datoteke ni uspelo",
|
"ToastDeleteFileFailed": "Brisanje datoteke ni uspelo",
|
||||||
"ToastDeleteFileSuccess": "Datoteka je bila izbrisana",
|
"ToastDeleteFileSuccess": "Datoteka je bila izbrisana",
|
||||||
"ToastDeviceAddFailed": "Naprave ni bilo mogoče dodati",
|
"ToastDeviceAddFailed": "Naprave ni bilo mogoče dodati",
|
||||||
@ -1015,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Izbrati morate vsaj eno oznako",
|
"ToastNewUserTagError": "Izbrati morate vsaj eno oznako",
|
||||||
"ToastNewUserUsernameError": "Vnesite uporabniško ime",
|
"ToastNewUserUsernameError": "Vnesite uporabniško ime",
|
||||||
"ToastNoNewEpisodesFound": "Ni novih epizod",
|
"ToastNoNewEpisodesFound": "Ni novih epizod",
|
||||||
|
"ToastNoRSSFeed": "Podcast nima RSS vira",
|
||||||
"ToastNoUpdatesNecessary": "Posodobitve niso potrebne",
|
"ToastNoUpdatesNecessary": "Posodobitve niso potrebne",
|
||||||
"ToastNotificationCreateFailed": "Obvestila ni bilo mogoče ustvariti",
|
"ToastNotificationCreateFailed": "Obvestila ni bilo mogoče ustvariti",
|
||||||
"ToastNotificationDeleteFailed": "Brisanje obvestila ni uspelo",
|
"ToastNotificationDeleteFailed": "Brisanje obvestila ni uspelo",
|
||||||
|
@ -19,6 +19,7 @@
|
|||||||
"ButtonChooseFiles": "Välj filer",
|
"ButtonChooseFiles": "Välj filer",
|
||||||
"ButtonClearFilter": "Rensa filter",
|
"ButtonClearFilter": "Rensa filter",
|
||||||
"ButtonCloseFeed": "Stäng flöde",
|
"ButtonCloseFeed": "Stäng flöde",
|
||||||
|
"ButtonCloseSession": "Stäng öppen session",
|
||||||
"ButtonCollections": "Samlingar",
|
"ButtonCollections": "Samlingar",
|
||||||
"ButtonConfigureScanner": "Konfigurera skanner",
|
"ButtonConfigureScanner": "Konfigurera skanner",
|
||||||
"ButtonCreate": "Skapa",
|
"ButtonCreate": "Skapa",
|
||||||
@ -28,11 +29,14 @@
|
|||||||
"ButtonEdit": "Redigera",
|
"ButtonEdit": "Redigera",
|
||||||
"ButtonEditChapters": "Redigera kapitel",
|
"ButtonEditChapters": "Redigera kapitel",
|
||||||
"ButtonEditPodcast": "Redigera podcast",
|
"ButtonEditPodcast": "Redigera podcast",
|
||||||
|
"ButtonEnable": "Aktivera",
|
||||||
"ButtonForceReScan": "Tvinga omstart",
|
"ButtonForceReScan": "Tvinga omstart",
|
||||||
"ButtonFullPath": "Fullständig sökväg",
|
"ButtonFullPath": "Fullständig sökväg",
|
||||||
"ButtonHide": "Dölj",
|
"ButtonHide": "Dölj",
|
||||||
"ButtonHome": "Hem",
|
"ButtonHome": "Hem",
|
||||||
"ButtonIssues": "Problem",
|
"ButtonIssues": "Problem",
|
||||||
|
"ButtonJumpBackward": "Hoppa bakåt",
|
||||||
|
"ButtonJumpForward": "Hoppa framåt",
|
||||||
"ButtonLatest": "Senaste",
|
"ButtonLatest": "Senaste",
|
||||||
"ButtonLibrary": "Bibliotek",
|
"ButtonLibrary": "Bibliotek",
|
||||||
"ButtonLogout": "Logga ut",
|
"ButtonLogout": "Logga ut",
|
||||||
@ -44,6 +48,7 @@
|
|||||||
"ButtonNevermind": "Glöm det",
|
"ButtonNevermind": "Glöm det",
|
||||||
"ButtonNext": "Nästa",
|
"ButtonNext": "Nästa",
|
||||||
"ButtonNextChapter": "Nästa kapitel",
|
"ButtonNextChapter": "Nästa kapitel",
|
||||||
|
"ButtonNextItemInQueue": "Nästa objekt i Kö",
|
||||||
"ButtonOk": "Ok",
|
"ButtonOk": "Ok",
|
||||||
"ButtonOpenFeed": "Öppna flöde",
|
"ButtonOpenFeed": "Öppna flöde",
|
||||||
"ButtonOpenManager": "Öppna Manager",
|
"ButtonOpenManager": "Öppna Manager",
|
||||||
@ -54,8 +59,9 @@
|
|||||||
"ButtonPlaylists": "Spellistor",
|
"ButtonPlaylists": "Spellistor",
|
||||||
"ButtonPrevious": "Föregående",
|
"ButtonPrevious": "Föregående",
|
||||||
"ButtonPreviousChapter": "Föregående kapitel",
|
"ButtonPreviousChapter": "Föregående kapitel",
|
||||||
|
"ButtonProbeAudioFile": "Analysera ljudfil",
|
||||||
"ButtonPurgeAllCache": "Rensa all cache",
|
"ButtonPurgeAllCache": "Rensa all cache",
|
||||||
"ButtonPurgeItemsCache": "Rensa föremåls-cache",
|
"ButtonPurgeItemsCache": "Rensa cache för föremål",
|
||||||
"ButtonQueueAddItem": "Lägg till i kön",
|
"ButtonQueueAddItem": "Lägg till i kön",
|
||||||
"ButtonQueueRemoveItem": "Ta bort från kön",
|
"ButtonQueueRemoveItem": "Ta bort från kön",
|
||||||
"ButtonQuickMatch": "Snabb matchning",
|
"ButtonQuickMatch": "Snabb matchning",
|
||||||
@ -66,10 +72,10 @@
|
|||||||
"ButtonRefresh": "Uppdatera",
|
"ButtonRefresh": "Uppdatera",
|
||||||
"ButtonRemove": "Ta bort",
|
"ButtonRemove": "Ta bort",
|
||||||
"ButtonRemoveAll": "Ta bort alla",
|
"ButtonRemoveAll": "Ta bort alla",
|
||||||
"ButtonRemoveAllLibraryItems": "Ta bort alla biblioteksobjekt",
|
"ButtonRemoveAllLibraryItems": "Ta bort alla objekt i biblioteket",
|
||||||
"ButtonRemoveFromContinueListening": "Ta bort från Fortsätt lyssna",
|
"ButtonRemoveFromContinueListening": "Radera från 'Fortsätt läsa/lyssna'",
|
||||||
"ButtonRemoveFromContinueReading": "Ta bort från Fortsätt läsa",
|
"ButtonRemoveFromContinueReading": "Ta bort från Fortsätt läsa",
|
||||||
"ButtonRemoveSeriesFromContinueSeries": "Ta bort serie från Fortsätt serie",
|
"ButtonRemoveSeriesFromContinueSeries": "Radera från 'Fortsätt med serien'",
|
||||||
"ButtonReset": "Återställ",
|
"ButtonReset": "Återställ",
|
||||||
"ButtonResetToDefault": "Återställ till standard",
|
"ButtonResetToDefault": "Återställ till standard",
|
||||||
"ButtonRestore": "Återställ",
|
"ButtonRestore": "Återställ",
|
||||||
@ -82,53 +88,60 @@
|
|||||||
"ButtonSelectFolderPath": "Välj mappens sökväg",
|
"ButtonSelectFolderPath": "Välj mappens sökväg",
|
||||||
"ButtonSeries": "Serier",
|
"ButtonSeries": "Serier",
|
||||||
"ButtonSetChaptersFromTracks": "Ställ in kapitel från spår",
|
"ButtonSetChaptersFromTracks": "Ställ in kapitel från spår",
|
||||||
|
"ButtonShare": "Dela",
|
||||||
"ButtonShiftTimes": "Förskjut tider",
|
"ButtonShiftTimes": "Förskjut tider",
|
||||||
"ButtonShow": "Visa",
|
"ButtonShow": "Visa",
|
||||||
"ButtonStartM4BEncode": "Starta M4B-kodning",
|
"ButtonStartM4BEncode": "Starta M4B-kodning",
|
||||||
"ButtonStartMetadataEmbed": "Starta inbäddning av metadata",
|
"ButtonStartMetadataEmbed": "Starta inbäddning av metadata",
|
||||||
"ButtonStats": "Statistik",
|
"ButtonStats": "Statistik",
|
||||||
"ButtonSubmit": "Skicka",
|
"ButtonSubmit": "Spara",
|
||||||
"ButtonTest": "Testa",
|
"ButtonTest": "Testa",
|
||||||
"ButtonUpload": "Ladda upp",
|
"ButtonUpload": "Ladda upp",
|
||||||
"ButtonUploadBackup": "Ladda upp säkerhetskopia",
|
"ButtonUploadBackup": "Ladda upp säkerhetskopia",
|
||||||
"ButtonUploadCover": "Ladda upp omslag",
|
"ButtonUploadCover": "Ladda upp bokomslag",
|
||||||
"ButtonUploadOPMLFile": "Ladda upp OPML-fil",
|
"ButtonUploadOPMLFile": "Ladda upp OPML-fil",
|
||||||
"ButtonUserDelete": "Radera användare {0}",
|
"ButtonUserDelete": "Radera användare {0}",
|
||||||
"ButtonUserEdit": "Redigera användare {0}",
|
"ButtonUserEdit": "Redigera användare {0}",
|
||||||
"ButtonViewAll": "Visa alla",
|
"ButtonViewAll": "Visa alla",
|
||||||
"ButtonYes": "Ja",
|
"ButtonYes": "Ja",
|
||||||
|
"ErrorUploadFetchMetadataAPI": "Fel vid hämtning av metadata",
|
||||||
|
"ErrorUploadFetchMetadataNoResults": "Metadata kunde inte hämtas - försök att ändra titel och/eller författare",
|
||||||
|
"ErrorUploadLacksTitle": "En titel måste anges",
|
||||||
"HeaderAccount": "Konto",
|
"HeaderAccount": "Konto",
|
||||||
|
"HeaderAddCustomMetadataProvider": "Addera egen källa för metadata",
|
||||||
"HeaderAdvanced": "Avancerad",
|
"HeaderAdvanced": "Avancerad",
|
||||||
"HeaderAppriseNotificationSettings": "Apprise Meddelandeinställningar",
|
"HeaderAppriseNotificationSettings": "Apprise Meddelandeinställningar",
|
||||||
"HeaderAudioTracks": "Ljudspår",
|
"HeaderAudioTracks": "Ljudspår",
|
||||||
"HeaderAudiobookTools": "Ljudbokshantering",
|
"HeaderAudiobookTools": "Hantering av ljudboksfil",
|
||||||
|
"HeaderAuthentication": "Autentisering",
|
||||||
"HeaderBackups": "Säkerhetskopior",
|
"HeaderBackups": "Säkerhetskopior",
|
||||||
"HeaderChangePassword": "Ändra lösenord",
|
"HeaderChangePassword": "Ändra lösenord",
|
||||||
"HeaderChapters": "Kapitel",
|
"HeaderChapters": "Kapitel",
|
||||||
"HeaderChooseAFolder": "Välj en mapp",
|
"HeaderChooseAFolder": "Välj en mapp",
|
||||||
"HeaderCollection": "Samling",
|
"HeaderCollection": "Samling",
|
||||||
"HeaderCollectionItems": "Samlingselement",
|
"HeaderCollectionItems": "Böcker i samlingen",
|
||||||
"HeaderCover": "Omslag",
|
"HeaderCover": "Bokomslag",
|
||||||
"HeaderCurrentDownloads": "Aktuella nedladdningar",
|
"HeaderCurrentDownloads": "Aktuella nedladdningar",
|
||||||
|
"HeaderCustomMetadataProviders": "Egen källa för metadata",
|
||||||
"HeaderDetails": "Detaljer",
|
"HeaderDetails": "Detaljer",
|
||||||
"HeaderDownloadQueue": "Nedladdningskö",
|
"HeaderDownloadQueue": "Nedladdningskö",
|
||||||
"HeaderEbookFiles": "E-boksfiler",
|
"HeaderEbookFiles": "E-boksfiler",
|
||||||
"HeaderEmail": "E-post",
|
"HeaderEmail": "E-postadress",
|
||||||
"HeaderEmailSettings": "E-postinställningar",
|
"HeaderEmailSettings": "Inställningar för e-post",
|
||||||
"HeaderEpisodes": "Avsnitt",
|
"HeaderEpisodes": "Avsnitt",
|
||||||
"HeaderEreaderDevices": "E-boksläsarenheter",
|
"HeaderEreaderDevices": "Enheter för att läsa e-böcker",
|
||||||
"HeaderEreaderSettings": "E-boksinställningar",
|
"HeaderEreaderSettings": "E-boksinställningar",
|
||||||
"HeaderFiles": "Filer",
|
"HeaderFiles": "Filer",
|
||||||
"HeaderFindChapters": "Hitta kapitel",
|
"HeaderFindChapters": "Hitta kapitel",
|
||||||
"HeaderIgnoredFiles": "Ignorerade filer",
|
"HeaderIgnoredFiles": "Ignorerade filer",
|
||||||
"HeaderItemFiles": "Föremålsfiler",
|
"HeaderItemFiles": "Föremålsfiler",
|
||||||
"HeaderItemMetadataUtils": "Metadataverktyg för föremål",
|
"HeaderItemMetadataUtils": "Metadataverktyg för föremål",
|
||||||
"HeaderLastListeningSession": "Senaste lyssningssession",
|
"HeaderLastListeningSession": "Senaste lyssningstillfället",
|
||||||
"HeaderLatestEpisodes": "Senaste avsnitt",
|
"HeaderLatestEpisodes": "Senaste avsnitten",
|
||||||
"HeaderLibraries": "Bibliotek",
|
"HeaderLibraries": "Bibliotek",
|
||||||
"HeaderLibraryFiles": "Biblioteksfiler",
|
"HeaderLibraryFiles": "Filer i biblioteket",
|
||||||
"HeaderLibraryStats": "Biblioteksstatistik",
|
"HeaderLibraryStats": "Biblioteksstatistik",
|
||||||
"HeaderListeningSessions": "Lyssningssessioner",
|
"HeaderListeningSessions": "Lyssningstillfällen",
|
||||||
"HeaderListeningStats": "Lyssningsstatistik",
|
"HeaderListeningStats": "Lyssningsstatistik",
|
||||||
"HeaderLogin": "Logga in",
|
"HeaderLogin": "Logga in",
|
||||||
"HeaderLogs": "Loggar",
|
"HeaderLogs": "Loggar",
|
||||||
@ -136,27 +149,31 @@
|
|||||||
"HeaderManageTags": "Hantera taggar",
|
"HeaderManageTags": "Hantera taggar",
|
||||||
"HeaderMapDetails": "Karta detaljer",
|
"HeaderMapDetails": "Karta detaljer",
|
||||||
"HeaderMatch": "Matcha",
|
"HeaderMatch": "Matcha",
|
||||||
"HeaderMetadataOrderOfPrecedence": "Metadataordning av företräde",
|
"HeaderMetadataOrderOfPrecedence": "Prioriteringsordning vid inläsning av metadata",
|
||||||
"HeaderMetadataToEmbed": "Metadata att bädda in",
|
"HeaderMetadataToEmbed": "Metadata att bädda in",
|
||||||
"HeaderNewAccount": "Nytt konto",
|
"HeaderNewAccount": "Nytt konto",
|
||||||
"HeaderNewLibrary": "Nytt bibliotek",
|
"HeaderNewLibrary": "Nytt bibliotek",
|
||||||
"HeaderNotifications": "Meddelanden",
|
"HeaderNotifications": "Meddelanden",
|
||||||
"HeaderOpenRSSFeed": "Öppna RSS-flöde",
|
"HeaderOpenRSSFeed": "Öppna RSS-flöde",
|
||||||
"HeaderOtherFiles": "Andra filer",
|
"HeaderOtherFiles": "Andra filer",
|
||||||
|
"HeaderPasswordAuthentication": "Lösenordsautentisering",
|
||||||
"HeaderPermissions": "Behörigheter",
|
"HeaderPermissions": "Behörigheter",
|
||||||
"HeaderPlayerQueue": "Spelarkö",
|
"HeaderPlayerQueue": "Spellista",
|
||||||
|
"HeaderPlayerSettings": "Inställningar för uppspelning",
|
||||||
"HeaderPlaylist": "Spellista",
|
"HeaderPlaylist": "Spellista",
|
||||||
"HeaderPlaylistItems": "Spellistobjekt",
|
"HeaderPlaylistItems": "Böcker i spellistan",
|
||||||
"HeaderPodcastsToAdd": "Podcaster att lägga till",
|
"HeaderPodcastsToAdd": "Podcaster att lägga till",
|
||||||
"HeaderPreviewCover": "Förhandsgranska omslag",
|
"HeaderPreviewCover": "Förhandsgranska bokomslag",
|
||||||
"HeaderRSSFeedGeneral": "RSS-information",
|
"HeaderRSSFeedGeneral": "RSS-information",
|
||||||
"HeaderRSSFeedIsOpen": "RSS-flödet är öppet",
|
"HeaderRSSFeedIsOpen": "RSS-flödet är öppet",
|
||||||
"HeaderRSSFeeds": "RSS-flöden",
|
"HeaderRSSFeeds": "RSS-flöden",
|
||||||
"HeaderRemoveEpisode": "Ta bort avsnitt",
|
"HeaderRemoveEpisode": "Ta bort avsnitt",
|
||||||
"HeaderRemoveEpisodes": "Ta bort {0} avsnitt",
|
"HeaderRemoveEpisodes": "Ta bort {0} avsnitt",
|
||||||
"HeaderSavedMediaProgress": "Sparad medieförlopp",
|
"HeaderSavedMediaProgress": "Sparad historik",
|
||||||
"HeaderSchedule": "Schema",
|
"HeaderSchedule": "Schema",
|
||||||
"HeaderScheduleLibraryScans": "Schemalagda biblioteksskanningar",
|
"HeaderScheduleEpisodeDownloads": "Schemalägg automatiska avsnittsnedladdningar",
|
||||||
|
"HeaderScheduleLibraryScans": "Schema för skanning av biblioteket",
|
||||||
|
"HeaderSession": "Session",
|
||||||
"HeaderSetBackupSchedule": "Ange schemaläggning för säkerhetskopia",
|
"HeaderSetBackupSchedule": "Ange schemaläggning för säkerhetskopia",
|
||||||
"HeaderSettings": "Inställningar",
|
"HeaderSettings": "Inställningar",
|
||||||
"HeaderSettingsDisplay": "Visning",
|
"HeaderSettingsDisplay": "Visning",
|
||||||
@ -164,55 +181,62 @@
|
|||||||
"HeaderSettingsGeneral": "Allmänt",
|
"HeaderSettingsGeneral": "Allmänt",
|
||||||
"HeaderSettingsScanner": "Skanner",
|
"HeaderSettingsScanner": "Skanner",
|
||||||
"HeaderSettingsWebClient": "Webklient",
|
"HeaderSettingsWebClient": "Webklient",
|
||||||
"HeaderSleepTimer": "Sovtidtagare",
|
"HeaderSleepTimer": "Timer för att sova",
|
||||||
"HeaderStatsLargestItems": "Största objekt",
|
"HeaderStatsLargestItems": "Största objekten",
|
||||||
"HeaderStatsLongestItems": "Längsta objekt (tim)",
|
"HeaderStatsLongestItems": "Längsta objekten (timmar)",
|
||||||
"HeaderStatsMinutesListeningChart": "Minuters lyssning (senaste 7 dagar)",
|
"HeaderStatsMinutesListeningChart": "Minuters lyssning (senaste 7 dagarna)",
|
||||||
"HeaderStatsRecentSessions": "Senaste sessioner",
|
"HeaderStatsRecentSessions": "Senaste tillfällena",
|
||||||
"HeaderStatsTop10Authors": "10 populäraste författarna",
|
"HeaderStatsTop10Authors": "10 populäraste författarna",
|
||||||
"HeaderStatsTop5Genres": "5 populäraste kategorierna",
|
"HeaderStatsTop5Genres": "5 populäraste kategorierna",
|
||||||
"HeaderTableOfContents": "Innehållsförteckning",
|
"HeaderTableOfContents": "Innehållsförteckning",
|
||||||
"HeaderTools": "Verktyg",
|
"HeaderTools": "Verktyg",
|
||||||
"HeaderUpdateAccount": "Uppdatera konto",
|
"HeaderUpdateAccount": "Uppdatera konto",
|
||||||
"HeaderUpdateAuthor": "Uppdatera författare",
|
"HeaderUpdateAuthor": "Uppdatera författare",
|
||||||
"HeaderUpdateDetails": "Uppdatera detaljer",
|
"HeaderUpdateDetails": "Uppdatera detaljer om boken",
|
||||||
"HeaderUpdateLibrary": "Uppdatera bibliotek",
|
"HeaderUpdateLibrary": "Uppdatera bibliotek",
|
||||||
"HeaderUsers": "Användare",
|
"HeaderUsers": "Användare",
|
||||||
"HeaderYearReview": "Sammanställning för {0}",
|
"HeaderYearReview": "Sammanställning av {0}",
|
||||||
"HeaderYourStats": "Din statistik",
|
"HeaderYourStats": "Din statistik",
|
||||||
"LabelAbridged": "Förkortad",
|
"LabelAbridged": "Förkortad",
|
||||||
|
"LabelAccessibleBy": "Tillgänglig för",
|
||||||
"LabelAccountType": "Kontotyp",
|
"LabelAccountType": "Kontotyp",
|
||||||
|
"LabelAccountTypeAdmin": "Administratör",
|
||||||
"LabelAccountTypeGuest": "Gäst",
|
"LabelAccountTypeGuest": "Gäst",
|
||||||
"LabelAccountTypeUser": "Användare",
|
"LabelAccountTypeUser": "Användare",
|
||||||
"LabelActivity": "Aktivitet",
|
"LabelActivity": "Aktivitet",
|
||||||
"LabelAddToCollection": "Lägg till i Samling",
|
"LabelAddToCollection": "Lägg till i en Samling",
|
||||||
"LabelAddToCollectionBatch": "Lägg till {0} böcker i Samlingen",
|
"LabelAddToCollectionBatch": "Lägg till {0} böcker i en Samling",
|
||||||
"LabelAddToPlaylist": "Lägg till i Spellista",
|
"LabelAddToPlaylist": "Lägg till i Spellista",
|
||||||
"LabelAddToPlaylistBatch": "Lägg till {0} objekt i Spellistan",
|
"LabelAddToPlaylistBatch": "Lägg till {0} objekt i Spellistan",
|
||||||
"LabelAddedAt": "Tillagd vid",
|
"LabelAddedAt": "Datum adderad",
|
||||||
|
"LabelAddedDate": "Adderad {0}",
|
||||||
"LabelAdminUsersOnly": "Endast administratörer",
|
"LabelAdminUsersOnly": "Endast administratörer",
|
||||||
"LabelAll": "Alla",
|
"LabelAll": "Alla",
|
||||||
"LabelAllUsers": "Alla användare",
|
"LabelAllUsers": "Alla användare",
|
||||||
"LabelAllUsersExcludingGuests": "Alla användare utom gäster",
|
"LabelAllUsersExcludingGuests": "Alla användare utom gäster",
|
||||||
"LabelAllUsersIncludingGuests": "Alla användare inklusive gäster",
|
"LabelAllUsersIncludingGuests": "Alla användare inklusive gäster",
|
||||||
"LabelAlreadyInYourLibrary": "Redan i din samling",
|
"LabelAlreadyInYourLibrary": "Redan i din samling",
|
||||||
|
"LabelApiToken": "API-token",
|
||||||
"LabelAppend": "Lägg till",
|
"LabelAppend": "Lägg till",
|
||||||
"LabelAuthor": "Författare",
|
"LabelAuthor": "Författare",
|
||||||
"LabelAuthorFirstLast": "Författare (Förnamn Efternamn)",
|
"LabelAuthorFirstLast": "Författare (För-, Efternamn)",
|
||||||
"LabelAuthorLastFirst": "Författare (Efternamn, Förnamn)",
|
"LabelAuthorLastFirst": "Författare (Efter-, Förnamn)",
|
||||||
"LabelAuthors": "Författare",
|
"LabelAuthors": "Författare",
|
||||||
"LabelAutoDownloadEpisodes": "Automatisk nedladdning av avsnitt",
|
"LabelAutoDownloadEpisodes": "Automatisk nedladdning av avsnitt",
|
||||||
"LabelAutoFetchMetadata": "Automatisk nedladdning av metadata",
|
"LabelAutoFetchMetadata": "Automatisk nedladdning av metadata",
|
||||||
"LabelAutoFetchMetadataHelp": "Hämtar metadata för titel, författare och serier. Kompletterande metadata får adderas efter uppladdningen.",
|
"LabelAutoFetchMetadataHelp": "Hämtar metadata för titel, författare och serier. Kompletterande metadata kan manuellt adderas efter uppladdningen.",
|
||||||
|
"LabelAutoRegisterDescription": "Skapa automatiskt nya användare efter inloggning",
|
||||||
"LabelBackToUser": "Tillbaka till användaren",
|
"LabelBackToUser": "Tillbaka till användaren",
|
||||||
|
"LabelBackupAudioFiles": "Säkerhetskopiera ljudfiler",
|
||||||
"LabelBackupLocation": "Plats för säkerhetskopia",
|
"LabelBackupLocation": "Plats för säkerhetskopia",
|
||||||
"LabelBackupsEnableAutomaticBackups": "Aktivera automatiska säkerhetskopior",
|
"LabelBackupsEnableAutomaticBackups": "Aktivera automatisk säkerhetskopiering",
|
||||||
"LabelBackupsEnableAutomaticBackupsHelp": "Säkerhetskopior sparas i \"/metadata/backups\"",
|
"LabelBackupsEnableAutomaticBackupsHelp": "Säkerhetskopior sparas i \"/metadata/backups\"",
|
||||||
"LabelBackupsMaxBackupSize": "Maximal storlek på säkerhetskopia (i GB) (0 = obegränsad)",
|
"LabelBackupsMaxBackupSize": "Maximal storlek på säkerhetskopia (i GB) (0 = obegränsad)",
|
||||||
"LabelBackupsMaxBackupSizeHelp": "Som ett skydd mot felkonfiguration kommer säkerhetskopior att misslyckas om de överskrider den konfigurerade storleken.",
|
"LabelBackupsMaxBackupSizeHelp": "Som ett skydd mot en felaktig konfiguration kommer säkerhetskopior inte att genomföras om de överskrider den konfigurerade storleken.",
|
||||||
"LabelBackupsNumberToKeep": "Antal säkerhetskopior att behålla",
|
"LabelBackupsNumberToKeep": "Antal säkerhetskopior att behålla",
|
||||||
"LabelBackupsNumberToKeepHelp": "Endast en säkerhetskopia tas bort åt gången, så om du redan har fler säkerhetskopior än detta bör du ta bort dem manuellt.",
|
"LabelBackupsNumberToKeepHelp": "Endast en gammal säkerhetskopia tas bort åt gången, så om du redan har fler säkerhetskopior än det angivna beloppet bör du ta bort dem manuellt.",
|
||||||
"LabelBitrate": "Bitfrekvens",
|
"LabelBitrate": "Bitfrekvens",
|
||||||
|
"LabelBonus": "Bonus",
|
||||||
"LabelBooks": "Böcker",
|
"LabelBooks": "Böcker",
|
||||||
"LabelButtonText": "Knapptext",
|
"LabelButtonText": "Knapptext",
|
||||||
"LabelByAuthor": "av {0}",
|
"LabelByAuthor": "av {0}",
|
||||||
@ -223,23 +247,26 @@
|
|||||||
"LabelChapters": "Kapitel",
|
"LabelChapters": "Kapitel",
|
||||||
"LabelChaptersFound": "hittade kapitel",
|
"LabelChaptersFound": "hittade kapitel",
|
||||||
"LabelClickForMoreInfo": "Klicka för mer information",
|
"LabelClickForMoreInfo": "Klicka för mer information",
|
||||||
|
"LabelClickToUseCurrentValue": "Klicka för att använda aktuellt värde",
|
||||||
"LabelClosePlayer": "Stäng spelaren",
|
"LabelClosePlayer": "Stäng spelaren",
|
||||||
"LabelCollapseSeries": "Fäll ihop serie",
|
"LabelCodec": "Codec",
|
||||||
|
"LabelCollapseSeries": "Komprimera serier",
|
||||||
"LabelCollection": "Samling",
|
"LabelCollection": "Samling",
|
||||||
"LabelCollections": "Samlingar",
|
"LabelCollections": "Samlingar",
|
||||||
"LabelComplete": "Komplett",
|
"LabelComplete": "Komplett",
|
||||||
"LabelConfirmPassword": "Bekräfta lösenord",
|
"LabelConfirmPassword": "Bekräfta lösenord",
|
||||||
"LabelContinueListening": "Fortsätt Lyssna",
|
"LabelContinueListening": "Fortsätt läsa/lyssna",
|
||||||
"LabelContinueReading": "Fortsätt Läsa",
|
"LabelContinueReading": "Fortsätt Läsa",
|
||||||
"LabelContinueSeries": "Fortsätt Serie",
|
"LabelContinueSeries": "Fortsätt med serien",
|
||||||
"LabelCover": "Omslag",
|
"LabelCover": "Bokomslag",
|
||||||
"LabelCoverImageURL": "URL till omslagsbild",
|
"LabelCoverImageURL": "URL till omslagsbild",
|
||||||
"LabelCreatedAt": "Skapad vid",
|
"LabelCreatedAt": "Skapad",
|
||||||
"LabelCronExpression": "Cron-uttryck",
|
"LabelCronExpression": "Schemaläggning med hjälp av Cron (Cron Expression)",
|
||||||
"LabelCurrent": "Nuvarande",
|
"LabelCurrent": "Nuvarande",
|
||||||
"LabelCurrently": "För närvarande:",
|
"LabelCurrently": "För närvarande:",
|
||||||
"LabelCustomCronExpression": "Anpassat Cron-uttryck:",
|
"LabelCustomCronExpression": "Anpassat Cron-uttryck:",
|
||||||
"LabelDatetime": "Datum och tid",
|
"LabelDatetime": "Datum och klockslag",
|
||||||
|
"LabelDays": "Dagar",
|
||||||
"LabelDeleteFromFileSystemCheckbox": "Ta bort från filsystem (avmarkera för att endast ta bort från databasen)",
|
"LabelDeleteFromFileSystemCheckbox": "Ta bort från filsystem (avmarkera för att endast ta bort från databasen)",
|
||||||
"LabelDescription": "Beskrivning",
|
"LabelDescription": "Beskrivning",
|
||||||
"LabelDeselectAll": "Avmarkera alla",
|
"LabelDeselectAll": "Avmarkera alla",
|
||||||
@ -252,103 +279,126 @@
|
|||||||
"LabelDiscover": "Upptäck",
|
"LabelDiscover": "Upptäck",
|
||||||
"LabelDownload": "Ladda ner",
|
"LabelDownload": "Ladda ner",
|
||||||
"LabelDownloadNEpisodes": "Ladda ner {0} avsnitt",
|
"LabelDownloadNEpisodes": "Ladda ner {0} avsnitt",
|
||||||
|
"LabelDownloadable": "Nedladdningsbar",
|
||||||
"LabelDuration": "Varaktighet",
|
"LabelDuration": "Varaktighet",
|
||||||
|
"LabelDurationComparisonExactMatch": "(exakt matchning)",
|
||||||
"LabelDurationFound": "Varaktighet hittad:",
|
"LabelDurationFound": "Varaktighet hittad:",
|
||||||
"LabelEbook": "E-bok",
|
"LabelEbook": "E-bok",
|
||||||
"LabelEbooks": "Eböcker",
|
"LabelEbooks": "E-böcker",
|
||||||
"LabelEdit": "Redigera",
|
"LabelEdit": "Redigera",
|
||||||
"LabelEmail": "E-post",
|
"LabelEmail": "E-postadress",
|
||||||
"LabelEmailSettingsFromAddress": "Från adress",
|
"LabelEmailSettingsFromAddress": "Från e-postadress",
|
||||||
|
"LabelEmailSettingsRejectUnauthorized": "Avvisa icke-autentiserade certifikat",
|
||||||
|
"LabelEmailSettingsRejectUnauthorizedHelp": "Inaktivering av SSL-certifikatsvalidering kan exponera din anslutning för säkerhetsrisker, såsom man-in-the-middle-attacker. Inaktivera bara denna inställning om du förstår implikationerna och litar på den epostserver du ansluter till.",
|
||||||
"LabelEmailSettingsSecure": "Säker",
|
"LabelEmailSettingsSecure": "Säker",
|
||||||
"LabelEmailSettingsSecureHelp": "Om sant kommer anslutningen att använda TLS vid anslutning till servern. Om falskt används TLS om servern stöder STARTTLS-tillägget. I de flesta fall, om du ansluter till port 465, bör du ställa in detta värde till sant. För port 587 eller 25, låt det vara falskt. (från nodemailer.com/smtp/#authentication)",
|
"LabelEmailSettingsSecureHelp": "Om sant kommer anslutningen att använda TLS vid anslutning till servern. Om falskt används TLS om servern stöder STARTTLS-tillägget. I de flesta fall, om du ansluter till port 465, bör du ställa in detta värde till sant. För port 587 eller 25, låt det vara falskt. (från nodemailer.com/smtp/#authentication)",
|
||||||
"LabelEmailSettingsTestAddress": "Testadress",
|
"LabelEmailSettingsTestAddress": "E-postadress för test",
|
||||||
"LabelEmbeddedCover": "Inbäddat omslag",
|
"LabelEmbeddedCover": "Inbäddat bokomslag",
|
||||||
"LabelEnable": "Aktivera",
|
"LabelEnable": "Aktivera",
|
||||||
|
"LabelEncodingBackupLocation": "En säkerhetskopia av dina orginalljudfiler kommer att lagras i:",
|
||||||
"LabelEnd": "Slut",
|
"LabelEnd": "Slut",
|
||||||
"LabelEndOfChapter": "Slut av kapitel",
|
"LabelEndOfChapter": "Slut av kapitel",
|
||||||
"LabelEpisode": "Avsnitt",
|
"LabelEpisode": "Avsnitt",
|
||||||
"LabelEpisodeTitle": "Avsnittsrubrik",
|
"LabelEpisodeTitle": "Avsnittsrubrik",
|
||||||
"LabelEpisodeType": "Avsnittstyp",
|
"LabelEpisodeType": "Avsnittstyp",
|
||||||
"LabelExample": "Exempel",
|
"LabelExample": "Exempel",
|
||||||
|
"LabelExpandSeries": "Expandera serier",
|
||||||
"LabelFeedURL": "Flödes-URL",
|
"LabelFeedURL": "Flödes-URL",
|
||||||
|
"LabelFetchingMetadata": "Hämtar metadata",
|
||||||
"LabelFile": "Fil",
|
"LabelFile": "Fil",
|
||||||
"LabelFileBirthtime": "Födelse-tidpunkt för fil",
|
"LabelFileBirthtime": "Tidpunkt, filen skapades",
|
||||||
"LabelFileModified": "Fil ändrad",
|
"LabelFileModified": "Tidpunkt, filen ändrades",
|
||||||
|
"LabelFileModifiedDate": "Ändrad {0}",
|
||||||
"LabelFilename": "Filnamn",
|
"LabelFilename": "Filnamn",
|
||||||
"LabelFilterByUser": "Filtrera efter användare",
|
"LabelFilterByUser": "Välj användare",
|
||||||
"LabelFindEpisodes": "Hitta avsnitt",
|
"LabelFindEpisodes": "Hitta avsnitt",
|
||||||
"LabelFinished": "Avslutad",
|
"LabelFinished": "Avslutad",
|
||||||
"LabelFolder": "Mapp",
|
"LabelFolder": "Mapp",
|
||||||
"LabelFolders": "Mappar",
|
"LabelFolders": "Mappar",
|
||||||
|
"LabelFontBold": "Fetstil",
|
||||||
"LabelFontBoldness": "Fetstil",
|
"LabelFontBoldness": "Fetstil",
|
||||||
"LabelFontFamily": "Teckensnittsfamilj",
|
"LabelFontFamily": "Typsnittsfamilj",
|
||||||
"LabelFontScale": "Teckensnittsskala",
|
"LabelFontItalic": "Kursiverad",
|
||||||
|
"LabelFontScale": "Skala på typsnitt",
|
||||||
|
"LabelFontStrikethrough": "Genomstruken",
|
||||||
"LabelGenre": "Kategori",
|
"LabelGenre": "Kategori",
|
||||||
"LabelGenres": "Kategorier",
|
"LabelGenres": "Kategorier",
|
||||||
"LabelHardDeleteFile": "Hård radering av fil",
|
"LabelHardDeleteFile": "Hård radering av fil",
|
||||||
"LabelHasEbook": "Har E-bok",
|
"LabelHasEbook": "Har e-bok",
|
||||||
"LabelHasSupplementaryEbook": "Har komplimenterande E-bok",
|
"LabelHasSupplementaryEbook": "Har kompletterande e-bok",
|
||||||
|
"LabelHideSubtitles": "Dölj underrubriker",
|
||||||
|
"LabelHighestPriority": "Högst prioritet",
|
||||||
"LabelHost": "Värd",
|
"LabelHost": "Värd",
|
||||||
"LabelHour": "Timme",
|
"LabelHour": "Timme",
|
||||||
|
"LabelHours": "Timmar",
|
||||||
"LabelIcon": "Ikon",
|
"LabelIcon": "Ikon",
|
||||||
"LabelImageURLFromTheWeb": "Bild-URL från webben",
|
"LabelImageURLFromTheWeb": "Skriv URL-adressen till bilden på webben",
|
||||||
"LabelInProgress": "Pågående",
|
"LabelInProgress": "Pågående",
|
||||||
"LabelIncludeInTracklist": "Inkludera i spårlista",
|
"LabelIncludeInTracklist": "Inkludera i spårlista",
|
||||||
"LabelIncomplete": "Ofullständig",
|
"LabelIncomplete": "Ofullständig",
|
||||||
"LabelInterval": "Intervall",
|
"LabelInterval": "Intervall",
|
||||||
"LabelIntervalCustomDailyWeekly": "Anpassat dagligt/veckovis",
|
"LabelIntervalCustomDailyWeekly": "Anpassad daglig/veckovis",
|
||||||
"LabelIntervalEvery12Hours": "Var 12:e timme",
|
"LabelIntervalEvery12Hours": "Var 12:e timme",
|
||||||
"LabelIntervalEvery15Minutes": "Var 15:e minut",
|
"LabelIntervalEvery15Minutes": "Var 15:e minut",
|
||||||
"LabelIntervalEvery2Hours": "Var 2:e timme",
|
"LabelIntervalEvery2Hours": "Varannan timme",
|
||||||
"LabelIntervalEvery30Minutes": "Var 30:e minut",
|
"LabelIntervalEvery30Minutes": "Var 30:e minut",
|
||||||
"LabelIntervalEvery6Hours": "Var 6:e timme",
|
"LabelIntervalEvery6Hours": "Var 6:e timme",
|
||||||
"LabelIntervalEveryDay": "Varje dag",
|
"LabelIntervalEveryDay": "Varje dag",
|
||||||
"LabelIntervalEveryHour": "Varje timme",
|
"LabelIntervalEveryHour": "Varje timme",
|
||||||
"LabelInvert": "Invertera",
|
"LabelInvert": "Invertera",
|
||||||
"LabelItem": "Objekt",
|
"LabelItem": "Objekt",
|
||||||
|
"LabelJumpBackwardAmount": "Inställning för \"hopp bakåt\"",
|
||||||
|
"LabelJumpForwardAmount": "Inställning för \"hopp framåt\"",
|
||||||
"LabelLanguage": "Språk",
|
"LabelLanguage": "Språk",
|
||||||
"LabelLanguageDefaultServer": "Standardspråk för server",
|
"LabelLanguageDefaultServer": "Standardspråk för server",
|
||||||
"LabelLastBookAdded": "Senaste bok tillagd",
|
"LabelLanguages": "Språk",
|
||||||
"LabelLastBookUpdated": "Senaste bok uppdaterad",
|
"LabelLastBookAdded": "Bok senast tillagd",
|
||||||
"LabelLastSeen": "Senast sedd",
|
"LabelLastBookUpdated": "Bok senast uppdaterad",
|
||||||
"LabelLastTime": "Senaste gången",
|
"LabelLastSeen": "Senast inloggad",
|
||||||
"LabelLastUpdate": "Senaste uppdatering",
|
"LabelLastTime": "Senaste tillfället",
|
||||||
|
"LabelLastUpdate": "Senast uppdaterad",
|
||||||
"LabelLayout": "Layout",
|
"LabelLayout": "Layout",
|
||||||
"LabelLayoutSinglePage": "En sida",
|
"LabelLayoutSinglePage": "En sida",
|
||||||
"LabelLayoutSplitPage": "Dela sida",
|
"LabelLayoutSplitPage": "Uppslag",
|
||||||
"LabelLess": "Mindre",
|
"LabelLess": "Mindre",
|
||||||
"LabelLibrariesAccessibleToUser": "Åtkomliga bibliotek för användare",
|
"LabelLibrariesAccessibleToUser": "Bibliotek användaren har tillgång till",
|
||||||
"LabelLibrary": "Bibliotek",
|
"LabelLibrary": "Bibliotek",
|
||||||
"LabelLibraryItem": "Biblioteksobjekt",
|
"LabelLibraryItem": "Objekt",
|
||||||
"LabelLibraryName": "Biblioteksnamn",
|
"LabelLibraryName": "Biblioteksnamn",
|
||||||
"LabelLimit": "Begränsning",
|
"LabelLimit": "Begränsning",
|
||||||
"LabelLineSpacing": "Radavstånd",
|
"LabelLineSpacing": "Radavstånd",
|
||||||
"LabelListenAgain": "Lyssna igen",
|
"LabelListenAgain": "Läs/Lyssna igen",
|
||||||
"LabelLogLevelDebug": "Felsökningsnivå: Felsökning",
|
"LabelLogLevelDebug": "Felsökning",
|
||||||
"LabelLogLevelInfo": "Felsökningsnivå: Information",
|
"LabelLogLevelInfo": "Information",
|
||||||
"LabelLogLevelWarn": "Felsökningsnivå: Varning",
|
"LabelLogLevelWarn": "Varningar",
|
||||||
"LabelLookForNewEpisodesAfterDate": "Sök efter nya avsnitt efter detta datum",
|
"LabelLookForNewEpisodesAfterDate": "Sök efter nya avsnitt efter detta datum",
|
||||||
|
"LabelLowestPriority": "Lägst prioritet",
|
||||||
"LabelMediaPlayer": "Mediaspelare",
|
"LabelMediaPlayer": "Mediaspelare",
|
||||||
"LabelMediaType": "Mediatyp",
|
"LabelMediaType": "Mediatyp",
|
||||||
"LabelMetaTag": "Metamärke",
|
"LabelMetaTag": "Metamärke",
|
||||||
"LabelMetaTags": "Metamärken",
|
"LabelMetaTags": "Metamärken",
|
||||||
|
"LabelMetadataOrderOfPrecedenceDescription": "Källor för metadata med högre prioritet har företräde före källor med lägre prioritet",
|
||||||
"LabelMetadataProvider": "Källa för metadata",
|
"LabelMetadataProvider": "Källa för metadata",
|
||||||
"LabelMinute": "Minut",
|
"LabelMinute": "Minut",
|
||||||
"LabelMissing": "Saknad",
|
"LabelMinutes": "Minuter",
|
||||||
|
"LabelMissing": "Saknar",
|
||||||
|
"LabelMissingEbook": "Saknar e-bok",
|
||||||
|
"LabelMissingSupplementaryEbook": "Saknar kompletterande e-bok",
|
||||||
"LabelMore": "Mer",
|
"LabelMore": "Mer",
|
||||||
"LabelMoreInfo": "Mer information",
|
"LabelMoreInfo": "Mer information",
|
||||||
"LabelName": "Namn",
|
"LabelName": "Namn",
|
||||||
"LabelNarrator": "Uppläsare",
|
"LabelNarrator": "Uppläsare",
|
||||||
"LabelNarrators": "Uppläsare",
|
"LabelNarrators": "Uppläsare",
|
||||||
"LabelNew": "Ny",
|
"LabelNew": "Nytt",
|
||||||
"LabelNewPassword": "Nytt lösenord",
|
"LabelNewPassword": "Nytt lösenord",
|
||||||
"LabelNewestAuthors": "Senast tillagda författare",
|
"LabelNewestAuthors": "Senast adderade författare",
|
||||||
"LabelNewestEpisodes": "Senast tillagda avsnitt",
|
"LabelNewestEpisodes": "Senast tillagda avsnitt",
|
||||||
"LabelNextBackupDate": "Nästa datum för säkerhetskopia",
|
"LabelNextBackupDate": "Nästa datum för säkerhetskopiering",
|
||||||
"LabelNextScheduledRun": "Nästa schemalagda körning",
|
"LabelNextScheduledRun": "Nästa schemalagda körning",
|
||||||
|
"LabelNoCustomMetadataProviders": "Ingen egen källa för metadata",
|
||||||
"LabelNoEpisodesSelected": "Inga avsnitt valda",
|
"LabelNoEpisodesSelected": "Inga avsnitt valda",
|
||||||
"LabelNotFinished": "Ej avslutad",
|
"LabelNotFinished": "Ej avslutad",
|
||||||
"LabelNotStarted": "Inte påbörjad",
|
"LabelNotStarted": "Ej påbörjad",
|
||||||
"LabelNotes": "Anteckningar",
|
"LabelNotes": "Anteckningar",
|
||||||
"LabelNotificationAppriseURL": "Apprise URL(er)",
|
"LabelNotificationAppriseURL": "Apprise URL(er)",
|
||||||
"LabelNotificationAvailableVariables": "Tillgängliga variabler",
|
"LabelNotificationAvailableVariables": "Tillgängliga variabler",
|
||||||
@ -363,22 +413,27 @@
|
|||||||
"LabelNumberOfEpisodes": "Antal avsnitt",
|
"LabelNumberOfEpisodes": "Antal avsnitt",
|
||||||
"LabelOpenRSSFeed": "Öppna RSS-flöde",
|
"LabelOpenRSSFeed": "Öppna RSS-flöde",
|
||||||
"LabelOverwrite": "Skriv över",
|
"LabelOverwrite": "Skriv över",
|
||||||
|
"LabelPaginationPageXOfY": "Sida {0} av {1}",
|
||||||
"LabelPassword": "Lösenord",
|
"LabelPassword": "Lösenord",
|
||||||
"LabelPath": "Sökväg",
|
"LabelPath": "Sökväg",
|
||||||
"LabelPermissionsAccessAllLibraries": "Kan komma åt alla bibliotek",
|
"LabelPermissionsAccessAllLibraries": "Kan komma åt alla bibliotek",
|
||||||
"LabelPermissionsAccessAllTags": "Kan komma åt alla taggar",
|
"LabelPermissionsAccessAllTags": "Kan komma åt alla taggar",
|
||||||
"LabelPermissionsAccessExplicitContent": "Kan komma åt explicit innehåll",
|
"LabelPermissionsAccessExplicitContent": "Kan komma åt explicit innehåll",
|
||||||
|
"LabelPermissionsCreateEreader": "Kan addera e-läsarenhet",
|
||||||
"LabelPermissionsDelete": "Kan radera",
|
"LabelPermissionsDelete": "Kan radera",
|
||||||
"LabelPermissionsDownload": "Kan ladda ner",
|
"LabelPermissionsDownload": "Kan ladda ner",
|
||||||
"LabelPermissionsUpdate": "Kan uppdatera",
|
"LabelPermissionsUpdate": "Kan uppdatera",
|
||||||
"LabelPermissionsUpload": "Kan ladda upp",
|
"LabelPermissionsUpload": "Kan ladda upp",
|
||||||
|
"LabelPersonalYearReview": "En sammanställning av ditt år, sidan {0}",
|
||||||
"LabelPhotoPathURL": "Bildsökväg/URL",
|
"LabelPhotoPathURL": "Bildsökväg/URL",
|
||||||
"LabelPlayMethod": "Spelläge",
|
"LabelPlayMethod": "Spelläge",
|
||||||
|
"LabelPlayerChapterNumberMarker": "{0} av {1}",
|
||||||
"LabelPlaylists": "Spellistor",
|
"LabelPlaylists": "Spellistor",
|
||||||
"LabelPodcast": "Podcast",
|
"LabelPodcast": "Podcast",
|
||||||
"LabelPodcastSearchRegion": "Podcast-sökområde",
|
"LabelPodcastSearchRegion": "Podcast-sökområde",
|
||||||
"LabelPodcastType": "Podcasttyp",
|
"LabelPodcastType": "Podcasttyp",
|
||||||
"LabelPodcasts": "Podcasts",
|
"LabelPodcasts": "Podcasts",
|
||||||
|
"LabelPort": "Port",
|
||||||
"LabelPrefixesToIgnore": "Prefix att ignorera (skiftlägesokänsligt)",
|
"LabelPrefixesToIgnore": "Prefix att ignorera (skiftlägesokänsligt)",
|
||||||
"LabelPreventIndexing": "Förhindra att ditt flöde indexeras av iTunes och Google-podcastsökmotorer",
|
"LabelPreventIndexing": "Förhindra att ditt flöde indexeras av iTunes och Google-podcastsökmotorer",
|
||||||
"LabelPrimaryEbook": "Primär e-bok",
|
"LabelPrimaryEbook": "Primär e-bok",
|
||||||
@ -386,6 +441,7 @@
|
|||||||
"LabelProvider": "Källa",
|
"LabelProvider": "Källa",
|
||||||
"LabelPubDate": "Publiceringsdatum",
|
"LabelPubDate": "Publiceringsdatum",
|
||||||
"LabelPublishYear": "Publiceringsår",
|
"LabelPublishYear": "Publiceringsår",
|
||||||
|
"LabelPublishedDecade": "Årtionde för publicering",
|
||||||
"LabelPublisher": "Utgivare",
|
"LabelPublisher": "Utgivare",
|
||||||
"LabelRSSFeedCustomOwnerEmail": "Anpassad ägarens e-post",
|
"LabelRSSFeedCustomOwnerEmail": "Anpassad ägarens e-post",
|
||||||
"LabelRSSFeedCustomOwnerName": "Anpassat ägarnamn",
|
"LabelRSSFeedCustomOwnerName": "Anpassat ägarnamn",
|
||||||
@ -397,15 +453,22 @@
|
|||||||
"LabelRead": "Läst",
|
"LabelRead": "Läst",
|
||||||
"LabelReadAgain": "Läs igen",
|
"LabelReadAgain": "Läs igen",
|
||||||
"LabelReadEbookWithoutProgress": "Läs e-bok utan att behålla framsteg",
|
"LabelReadEbookWithoutProgress": "Läs e-bok utan att behålla framsteg",
|
||||||
"LabelRecentSeries": "Senaste serier",
|
"LabelRecentSeries": "Senaste serierna",
|
||||||
"LabelRecentlyAdded": "Nyligen tillagd",
|
"LabelRecentlyAdded": "Nyligen tillagda",
|
||||||
"LabelRecommended": "Rekommenderad",
|
"LabelRecommended": "Rekommenderad",
|
||||||
|
"LabelRegion": "Region",
|
||||||
"LabelReleaseDate": "Utgivningsdatum",
|
"LabelReleaseDate": "Utgivningsdatum",
|
||||||
"LabelRemoveCover": "Ta bort omslag",
|
"LabelRemoveAllMetadataAbs": "Radera alla 'metadata.abs' filer",
|
||||||
"LabelSearchTerm": "Sökterm",
|
"LabelRemoveAllMetadataJson": "Radera alla 'metadata.json' filer",
|
||||||
"LabelSearchTitle": "Sök titel",
|
"LabelRemoveCover": "Ta bort bokomslag",
|
||||||
|
"LabelRemoveMetadataFile": "Radera metadata-filer i alla mappar i biblioteket",
|
||||||
|
"LabelRemoveMetadataFileHelp": "Radera alla 'metadata.json' och 'metadata.abs' filer i dina {0} mappar.",
|
||||||
|
"LabelRowsPerPage": "Antal rader per sida",
|
||||||
|
"LabelSearchTerm": "Sökbegrepp",
|
||||||
|
"LabelSearchTitle": "Titel",
|
||||||
"LabelSearchTitleOrASIN": "Sök titel eller ASIN-kod",
|
"LabelSearchTitleOrASIN": "Sök titel eller ASIN-kod",
|
||||||
"LabelSeason": "Säsong",
|
"LabelSeason": "Säsong",
|
||||||
|
"LabelSelectAll": "Välj alla",
|
||||||
"LabelSelectAllEpisodes": "Välj alla avsnitt",
|
"LabelSelectAllEpisodes": "Välj alla avsnitt",
|
||||||
"LabelSelectEpisodesShowing": "Välj {0} avsnitt som visas",
|
"LabelSelectEpisodesShowing": "Välj {0} avsnitt som visas",
|
||||||
"LabelSelectUsers": "Välj användare",
|
"LabelSelectUsers": "Välj användare",
|
||||||
@ -413,62 +476,77 @@
|
|||||||
"LabelSequence": "Sekvens",
|
"LabelSequence": "Sekvens",
|
||||||
"LabelSeries": "Serier",
|
"LabelSeries": "Serier",
|
||||||
"LabelSeriesName": "Serienamn",
|
"LabelSeriesName": "Serienamn",
|
||||||
"LabelSeriesProgress": "Serieframsteg",
|
"LabelSeriesProgress": "Status för serier",
|
||||||
"LabelSetEbookAsPrimary": "Ange som primär",
|
"LabelServerLogLevel": "Nivå på loggning",
|
||||||
|
"LabelServerYearReview": "En sammanställning av ditt bibliotek, sidan {0}",
|
||||||
|
"LabelSetEbookAsPrimary": "Ange som primär fil",
|
||||||
"LabelSetEbookAsSupplementary": "Ange som kompletterande",
|
"LabelSetEbookAsSupplementary": "Ange som kompletterande",
|
||||||
|
"LabelSettingsAllowIframe": "Tillåt att Audiobookshelf får visas i en iframe",
|
||||||
"LabelSettingsAudiobooksOnly": "Endast ljudböcker",
|
"LabelSettingsAudiobooksOnly": "Endast ljudböcker",
|
||||||
"LabelSettingsAudiobooksOnlyHelp": "Aktivera detta alternativ kommer att ignorera e-boksfiler om de inte finns inom en ljudboksmapp, i vilket fall de kommer att anges som kompletterande e-böcker",
|
"LabelSettingsAudiobooksOnlyHelp": "När detta alternativ aktiveras kommer filer med e-böcker<br>att ignoreras om de inte lagras i en mapp med en ljudbok.<br>I det fallet kommer de att anges som en kompletterande e-bok",
|
||||||
"LabelSettingsBookshelfViewHelp": "Skeumorfisk design med trähyllor",
|
"LabelSettingsBookshelfViewHelp": "Bakgrund med ett utseende liknande en bokhylla i trä",
|
||||||
"LabelSettingsChromecastSupport": "Stöd för Chromecast",
|
"LabelSettingsChromecastSupport": "Stöd för Chromecast",
|
||||||
"LabelSettingsDateFormat": "Datumformat",
|
"LabelSettingsDateFormat": "Datumformat",
|
||||||
"LabelSettingsDisableWatcher": "Inaktivera Watcher",
|
"LabelSettingsDisableWatcher": "Inaktivera Watcher",
|
||||||
"LabelSettingsDisableWatcherForLibrary": "Inaktivera mappbevakning för bibliotek",
|
"LabelSettingsDisableWatcherForLibrary": "Inaktivera bevakning med Watcher för biblioteket",
|
||||||
"LabelSettingsDisableWatcherHelp": "Inaktiverar automatiskt lägga till/uppdatera objekt när filändringar upptäcks. *Kräver omstart av servern",
|
"LabelSettingsDisableWatcherHelp": "Inaktiverar automatik att addera/uppdatera objekt<br>när ändringar av filer genomförs.<br>OBS: Kräver en omstart av servern",
|
||||||
"LabelSettingsEnableWatcher": "Aktivera Watcher",
|
"LabelSettingsEnableWatcher": "Aktivera Watcher",
|
||||||
"LabelSettingsEnableWatcherForLibrary": "Aktivera mappbevakning för bibliotek",
|
"LabelSettingsEnableWatcherForLibrary": "Aktivera bevakning med Watcher för biblioteket",
|
||||||
"LabelSettingsEnableWatcherHelp": "Aktiverar automatiskt lägga till/uppdatera objekt när filändringar upptäcks. *Kräver omstart av servern",
|
"LabelSettingsEnableWatcherHelp": "Aktiverar automatik att addera/uppdatera objekt<br>när ändringar av filer genomförs.<br>OBS: Kräver en omstart av servern",
|
||||||
|
"LabelSettingsEpubsAllowScriptedContent": "Tillåt e-böcker i epubs-format som innehåller script",
|
||||||
|
"LabelSettingsEpubsAllowScriptedContentHelp": "Tillåt att epub-filer får använda script.<br>Det rekommenderas att denna inställning är<br>avstängd när du inte litar på källan för epub-filerna.",
|
||||||
"LabelSettingsExperimentalFeatures": "Experimentella funktioner",
|
"LabelSettingsExperimentalFeatures": "Experimentella funktioner",
|
||||||
"LabelSettingsExperimentalFeaturesHelp": "Funktioner under utveckling som behöver din feedback och hjälp med testning. Klicka för att öppna diskussionen på GitHub.",
|
"LabelSettingsExperimentalFeaturesHelp": "Funktioner under utveckling som behöver din feedback och hjälp med testning. Klicka för att öppna diskussionen på GitHub.",
|
||||||
"LabelSettingsFindCovers": "Hitta omslag",
|
"LabelSettingsFindCovers": "Hitta ett bokomslag",
|
||||||
"LabelSettingsFindCoversHelp": "Om din ljudbok inte har ett inbäddat omslag eller en omslagsbild i mappen kommer skannern att försöka hitta ett omslag.<br>Observera: Detta kommer att förlänga skannningstiden",
|
"LabelSettingsFindCoversHelp": "Om din bok inte har ett bokomslag inbäddat i filen eller<br>en fil med bokomslaget i mappen kommer<br>skannern att försöka hitta ett omslag.<br>OBS: Detta kommer att förlänga inläsningstiden",
|
||||||
"LabelSettingsHideSingleBookSeries": "Dölj serier med en bok",
|
"LabelSettingsHideSingleBookSeries": "Dölj serier som endast innehåller en bok",
|
||||||
"LabelSettingsHideSingleBookSeriesHelp": "Serier som har en enda bok kommer att döljas från seriesidan och hyllsidan på startsidan.",
|
"LabelSettingsHideSingleBookSeriesHelp": "Serier som endast har en bok kommer att<br>döljas från sidan 'Serier' och hyllorna på startsidan.",
|
||||||
"LabelSettingsHomePageBookshelfView": "Startsida använd bokhyllvy",
|
"LabelSettingsHomePageBookshelfView": "Använd vy liknande en bokhylla på startsidan",
|
||||||
"LabelSettingsLibraryBookshelfView": "Bibliotek använd bokhyllvy",
|
"LabelSettingsLibraryBookshelfView": "Använd vy liknande en bokhylla i biblioteket",
|
||||||
"LabelSettingsParseSubtitles": "Analysera undertexter",
|
"LabelSettingsLibraryMarkAsFinishedPercentComplete": "Procent genomfört är större än",
|
||||||
"LabelSettingsParseSubtitlesHelp": "Extrahera undertitlar från namnet på mappar för ljudböcker.<br>Undertiteln måste vara åtskilda med ett bindestreck \" - \".<br>Mappen \"Boktitel - En undertitel här\" har undertiteln \"En undertitel här\"",
|
"LabelSettingsLibraryMarkAsFinishedTimeRemaining": "Återstående tid är mindre än (sekunder)",
|
||||||
"LabelSettingsPreferMatchedMetadata": "Föredra matchad metadata",
|
"LabelSettingsLibraryMarkAsFinishedWhen": "Markera objekt som avslutade när",
|
||||||
|
"LabelSettingsOnlyShowLaterBooksInContinueSeries": "Hoppa över tidigare böcker i en serie",
|
||||||
|
"LabelSettingsOnlyShowLaterBooksInContinueSeriesHelp": "Sektionen 'Fortsätt med serien' på startsidan visar \"nästa bok\" i serien,<br>där åtminstone en bok avslutats, och ingen bok i serien har påbörjats.<br>Om detta alternativ aktiveras kommer efterföljande bok till den<br>avslutade att föreslås - istället för den första ej avslutade boken i serien.",
|
||||||
|
"LabelSettingsParseSubtitles": "Hämta undertitel från bokens mapp",
|
||||||
|
"LabelSettingsParseSubtitlesHelp": "Hämtar undertiteln från namnet på mappen där boken lagras.<br>Undertiteln måste vara åtskilda med ett bindestreck ' - '.<br>En mapp med namnet 'Boktitel - Bokens undertitel'<br> får undertiteln \"Bokens undertitel\"",
|
||||||
|
"LabelSettingsPreferMatchedMetadata": "Prioritera matchad metadata",
|
||||||
"LabelSettingsPreferMatchedMetadataHelp": "Matchad data kommer att åsidosätta objektdetaljer vid snabbmatchning. Som standard kommer snabbmatchning endast att fylla i saknade detaljer.",
|
"LabelSettingsPreferMatchedMetadataHelp": "Matchad data kommer att åsidosätta objektdetaljer vid snabbmatchning. Som standard kommer snabbmatchning endast att fylla i saknade detaljer.",
|
||||||
"LabelSettingsSkipMatchingBooksWithASIN": "Hoppa över matchande böcker med ASIN-kod",
|
"LabelSettingsSkipMatchingBooksWithASIN": "Hoppa över matchande böcker som har en ASIN-kod",
|
||||||
"LabelSettingsSkipMatchingBooksWithISBN": "Hoppa över matchande böcker med ISBN",
|
"LabelSettingsSkipMatchingBooksWithISBN": "Hoppa över matchande böcker som har en ISBN-kod",
|
||||||
"LabelSettingsSortingIgnorePrefixes": "Ignorera prefix vid sortering",
|
"LabelSettingsSortingIgnorePrefixes": "Ignorera prefix vid sortering",
|
||||||
"LabelSettingsSortingIgnorePrefixesHelp": "För prefix som t.ex. \"the\" kommer boktiteln \"The Book Title\" att sorteras som \"Book Title, The\"",
|
"LabelSettingsSortingIgnorePrefixesHelp": "För prefix som t.ex. \"the\" kommer boktiteln \"The Book Title\" att sorteras som \"Book Title, The\"",
|
||||||
"LabelSettingsSquareBookCovers": "Använd fyrkantiga bokomslag",
|
"LabelSettingsSquareBookCovers": "Använd kvadratiska bokomslag",
|
||||||
"LabelSettingsSquareBookCoversHelp": "Föredrar att använda fyrkantiga omslag över standard 1.6:1 bokomslag",
|
"LabelSettingsSquareBookCoversHelp": "Föredrar att använda kvadratiska bokomslag<br>före standardformatet 1.6:1",
|
||||||
"LabelSettingsStoreCoversWithItem": "Lagra omslag med objekt",
|
"LabelSettingsStoreCoversWithItem": "Lagra bokomslag med objektet",
|
||||||
"LabelSettingsStoreCoversWithItemHelp": "Som standard lagras bokomslag i mappen /metadata/items. Genom att aktivera detta alternativ kommer omslagen att lagra i din biblioteksmapp. Endast en fil med namnet \"cover\" kommer att behållas",
|
"LabelSettingsStoreCoversWithItemHelp": "Som standard lagras bokomslag i mappen '/metadata/items'.<br>Genom att aktivera detta alternativ kommer<br>omslagen att lagra i din biblioteksmapp.<br>Endast en fil med namnet 'cover' kommer att behållas",
|
||||||
"LabelSettingsStoreMetadataWithItem": "Lagra metadata med objekt",
|
"LabelSettingsStoreMetadataWithItem": "Lagra metadata med objektet",
|
||||||
"LabelSettingsStoreMetadataWithItemHelp": "Som standard lagras metadatafiler i mappen /metadata/items. Genom att aktivera detta alternativ kommer metadatafilerna att lagras i dina biblioteksmappar",
|
"LabelSettingsStoreMetadataWithItemHelp": "Som standard lagras metadatafiler i mappen '/metadata/items'. Genom att aktivera detta alternativ kommer metadatafilerna att lagra i din biblioteksmapp",
|
||||||
"LabelSettingsTimeFormat": "Tidsformat",
|
"LabelSettingsTimeFormat": "Tidsformat",
|
||||||
|
"LabelShare": "Dela",
|
||||||
"LabelShowAll": "Visa alla",
|
"LabelShowAll": "Visa alla",
|
||||||
|
"LabelShowSeconds": "Visa sekunder",
|
||||||
|
"LabelShowSubtitles": "Visa underrubriker",
|
||||||
"LabelSize": "Storlek",
|
"LabelSize": "Storlek",
|
||||||
"LabelSleepTimer": "Sleeptimer",
|
"LabelSleepTimer": "Timer för sova",
|
||||||
|
"LabelSortAscending": "Stigande",
|
||||||
|
"LabelSortDescending": "Fallande",
|
||||||
"LabelStart": "Starta",
|
"LabelStart": "Starta",
|
||||||
"LabelStartTime": "Starttid",
|
"LabelStartTime": "Starttid",
|
||||||
"LabelStarted": "Startad",
|
"LabelStarted": "Startad",
|
||||||
"LabelStartedAt": "Startad vid",
|
"LabelStartedAt": "Startades",
|
||||||
"LabelStatsAudioTracks": "Ljudspår",
|
"LabelStatsAudioTracks": "Ljudspår",
|
||||||
"LabelStatsAuthors": "Författare",
|
"LabelStatsAuthors": "Författare",
|
||||||
"LabelStatsBestDay": "Bästa dag",
|
"LabelStatsBestDay": "Bästa dag",
|
||||||
"LabelStatsDailyAverage": "Dagligt genomsnitt",
|
"LabelStatsDailyAverage": "Dagligt genomsnitt",
|
||||||
"LabelStatsDays": "Dagar",
|
"LabelStatsDays": "Dagar",
|
||||||
"LabelStatsDaysListened": "Dagar lyssnade",
|
"LabelStatsDaysListened": "dagars lyssnande",
|
||||||
"LabelStatsHours": "Timmar",
|
"LabelStatsHours": "Timmar",
|
||||||
"LabelStatsInARow": "i rad",
|
"LabelStatsInARow": "i rad",
|
||||||
"LabelStatsItemsFinished": "Objekt avslutade",
|
"LabelStatsItemsFinished": "böcker avslutade",
|
||||||
"LabelStatsItemsInLibrary": "Objekt i biblioteket",
|
"LabelStatsItemsInLibrary": "Objekt i biblioteket",
|
||||||
"LabelStatsMinutes": "minuter",
|
"LabelStatsMinutes": "minuter",
|
||||||
"LabelStatsMinutesListening": "Minuter av lyssnande",
|
"LabelStatsMinutesListening": "minuters lyssnande",
|
||||||
"LabelStatsOverallDays": "Totalt antal dagar",
|
"LabelStatsOverallDays": "Totalt antal dagar",
|
||||||
"LabelStatsOverallHours": "Totalt antal timmar",
|
"LabelStatsOverallHours": "Totalt antal timmar",
|
||||||
"LabelStatsWeekListening": "Veckans lyssnande",
|
"LabelStatsWeekListening": "Veckans lyssnande",
|
||||||
@ -476,10 +554,12 @@
|
|||||||
"LabelSupportedFileTypes": "Filtyper som accepteras",
|
"LabelSupportedFileTypes": "Filtyper som accepteras",
|
||||||
"LabelTag": "Tagg",
|
"LabelTag": "Tagg",
|
||||||
"LabelTags": "Taggar",
|
"LabelTags": "Taggar",
|
||||||
"LabelTagsAccessibleToUser": "Taggar tillgängliga för användaren",
|
"LabelTagsAccessibleToUser": "Taggar användaren har tillgång till",
|
||||||
"LabelTagsNotAccessibleToUser": "Taggar inte tillgängliga för användaren",
|
"LabelTagsNotAccessibleToUser": "Taggar inte tillgängliga för användaren",
|
||||||
"LabelTasks": "Körande uppgifter",
|
"LabelTasks": "Körande uppgifter",
|
||||||
"LabelTheme": "Tema",
|
"LabelTextEditorBulletedList": "Punktlista",
|
||||||
|
"LabelTextEditorNumberedList": "Numrerad lista",
|
||||||
|
"LabelTheme": "Utseende",
|
||||||
"LabelThemeDark": "Mörkt",
|
"LabelThemeDark": "Mörkt",
|
||||||
"LabelThemeLight": "Ljust",
|
"LabelThemeLight": "Ljust",
|
||||||
"LabelTimeBase": "Tidsbas",
|
"LabelTimeBase": "Tidsbas",
|
||||||
@ -496,7 +576,7 @@
|
|||||||
"LabelToolsEmbedMetadata": "Bädda in metadata",
|
"LabelToolsEmbedMetadata": "Bädda in metadata",
|
||||||
"LabelToolsEmbedMetadataDescription": "Bädda in metadata i ljudfiler, inklusive omslagsbild och kapitel.",
|
"LabelToolsEmbedMetadataDescription": "Bädda in metadata i ljudfiler, inklusive omslagsbild och kapitel.",
|
||||||
"LabelToolsMakeM4b": "Skapa M4B ljudbok",
|
"LabelToolsMakeM4b": "Skapa M4B ljudbok",
|
||||||
"LabelToolsMakeM4bDescription": "Skapa en .M4B ljudboksfil med inbäddad metadata, omslagsbild och kapitel.",
|
"LabelToolsMakeM4bDescription": "Skapa en ljudboksfil i M4B-format med inbäddad metadata, omslagsbild och kapitel.",
|
||||||
"LabelToolsSplitM4b": "Dela upp M4B-fil i MP3-filer",
|
"LabelToolsSplitM4b": "Dela upp M4B-fil i MP3-filer",
|
||||||
"LabelToolsSplitM4bDescription": "Skapa MP3-filer från en M4B-fil uppdelad i kapitel med inbäddad metadata, omslagsbild och kapitel.",
|
"LabelToolsSplitM4bDescription": "Skapa MP3-filer från en M4B-fil uppdelad i kapitel med inbäddad metadata, omslagsbild och kapitel.",
|
||||||
"LabelTotalDuration": "Total varaktighet",
|
"LabelTotalDuration": "Total varaktighet",
|
||||||
@ -510,78 +590,100 @@
|
|||||||
"LabelTrailer": "Trailer",
|
"LabelTrailer": "Trailer",
|
||||||
"LabelType": "Typ",
|
"LabelType": "Typ",
|
||||||
"LabelUnabridged": "Oavkortad",
|
"LabelUnabridged": "Oavkortad",
|
||||||
|
"LabelUndo": "Ångra",
|
||||||
"LabelUnknown": "Okänd",
|
"LabelUnknown": "Okänd",
|
||||||
"LabelUpdateCover": "Uppdatera omslag",
|
"LabelUpdateCover": "Uppdatera bokomslag",
|
||||||
"LabelUpdateCoverHelp": "Tillåt överskrivning av befintliga omslag för de valda böckerna när en matchning hittas",
|
"LabelUpdateCoverHelp": "Tillåt att befintliga bokomslag för de valda böckerna ersätts när en matchning hittas",
|
||||||
"LabelUpdateDetails": "Uppdatera detaljer",
|
"LabelUpdateDetails": "Uppdatera detaljer",
|
||||||
"LabelUpdateDetailsHelp": "Tillåt överskrivning av befintliga detaljer för de valda böckerna när en matchning hittas",
|
"LabelUpdateDetailsHelp": "Tillåt att befintliga detaljer för de valda böckerna ersätts när en matchning hittas",
|
||||||
"LabelUpdatedAt": "Uppdaterad vid",
|
"LabelUpdatedAt": "Uppdaterades",
|
||||||
"LabelUploaderDragAndDrop": "Dra och släpp filer eller mappar",
|
"LabelUploaderDragAndDrop": "Dra och släpp filer eller mappar",
|
||||||
|
"LabelUploaderDragAndDropFilesOnly": "Dra & släpp filer",
|
||||||
"LabelUploaderDropFiles": "Släpp filer",
|
"LabelUploaderDropFiles": "Släpp filer",
|
||||||
"LabelUploaderItemFetchMetadataHelp": "Hämtar automatiskt titel, författare och serier.",
|
"LabelUploaderItemFetchMetadataHelp": "Hämtar automatiskt titel, författare och serier",
|
||||||
|
"LabelUseAdvancedOptions": "Använd avancerade inställningar",
|
||||||
"LabelUseChapterTrack": "Använd kapitelspår",
|
"LabelUseChapterTrack": "Använd kapitelspår",
|
||||||
"LabelUseFullTrack": "Använd hela spåret",
|
"LabelUseFullTrack": "Använd hela spåret",
|
||||||
|
"LabelUseZeroForUnlimited": "0 = Obegränsad",
|
||||||
"LabelUser": "Användare",
|
"LabelUser": "Användare",
|
||||||
"LabelUsername": "Användarnamn",
|
"LabelUsername": "Användarnamn",
|
||||||
"LabelValue": "Värde",
|
"LabelValue": "Värde",
|
||||||
"LabelVersion": "Version",
|
"LabelVersion": "Version",
|
||||||
"LabelViewBookmarks": "Visa bokmärken",
|
"LabelViewBookmarks": "Bokmärken",
|
||||||
"LabelViewChapters": "Visa kapitel",
|
"LabelViewChapters": "Visa kapitel",
|
||||||
|
"LabelViewPlayerSettings": "Visa inställningar för uppspelning",
|
||||||
"LabelViewQueue": "Visa spellista",
|
"LabelViewQueue": "Visa spellista",
|
||||||
"LabelVolume": "Volym",
|
"LabelVolume": "Volym",
|
||||||
"LabelWeekdaysToRun": "Vardagar att köra",
|
"LabelWeekdaysToRun": "Veckodagar att köra skanning",
|
||||||
"LabelYearReviewHide": "Dölj sammanställning för året",
|
"LabelXBooks": "{0} böcker",
|
||||||
"LabelYearReviewShow": "Visa sammanställning för året",
|
"LabelXItems": "{0} objekt",
|
||||||
|
"LabelYearReviewHide": "Dölj årets sammanställning",
|
||||||
|
"LabelYearReviewShow": "Visa årets sammanställning",
|
||||||
"LabelYourAudiobookDuration": "Din ljudboks varaktighet",
|
"LabelYourAudiobookDuration": "Din ljudboks varaktighet",
|
||||||
"LabelYourBookmarks": "Dina bokmärken",
|
"LabelYourBookmarks": "Dina bokmärken",
|
||||||
"LabelYourPlaylists": "Dina spellistor",
|
"LabelYourPlaylists": "Dina spellistor",
|
||||||
"LabelYourProgress": "Din framsteg",
|
"LabelYourProgress": "Framsteg",
|
||||||
"MessageAddToPlayerQueue": "Lägg till i spellistan",
|
"MessageAddToPlayerQueue": "Lägg till i spellistan",
|
||||||
"MessageAppriseDescription": "För att använda den här funktionen behöver du ha en instans av <a href=\"https://github.com/caronc/apprise-api\" target=\"_blank\">Apprise API</a> igång eller en API som hanterar dessa begäranden. <br />Apprise API-urlen bör vara hela URL-sökvägen för att skicka meddelandet, t.ex., om din API-instans är tillgänglig på <code>http://192.168.1.1:8337</code>, bör du ange <code>http://192.168.1.1:8337/notify</code>.",
|
"MessageAppriseDescription": "För att använda den här funktionen behöver du ha en instans av <a href=\"https://github.com/caronc/apprise-api\" target=\"_blank\">Apprise API</a> igång eller en API som hanterar dessa begäranden. <br />Apprise API-urlen bör vara hela URL-sökvägen för att skicka meddelandet, t.ex., om din API-instans är tillgänglig på <code>http://192.168.1.1:8337</code>, bör du ange <code>http://192.168.1.1:8337/notify</code>.",
|
||||||
"MessageBackupsDescription": "Säkerhetskopieringar inkluderar användare, användares framsteg, biblioteksföremål, serverinställningar och bilder lagrade i <code>/metadata/items</code> & <code>/metadata/authors</code>. Säkerhetskopieringar inkluderar <strong>inte</strong> några filer lagrade i dina biblioteksmappar.",
|
"MessageBackupsDescription": "Säkerhetskopior inkluderar användare, användarnas framsteg, biblioteksobjekt, serverinställningar<br>och bilder lagrade i <code>/metadata/items</code> & <code>/metadata/authors</code>.<br>De inkluderar <strong>INTE</strong> några filer lagrade i dina biblioteksmappar.",
|
||||||
|
"MessageBackupsLocationEditNote": "OBS: När du ändrar plats för säkerhetskopiorna så flyttas INTE gamla säkerhetskopior dit",
|
||||||
|
"MessageBackupsLocationNoEditNote": "OBS: Platsen där säkerhetskopiorna lagras bestäms av en central inställning och kan inte ändras här.",
|
||||||
|
"MessageBackupsLocationPathEmpty": "Uppgiften om platsen för lagring av säkerhetskopior kan inte lämnas tom",
|
||||||
"MessageBatchQuickMatchDescription": "Quick Match kommer försöka lägga till saknade omslag och metadata för de valda föremålen. Aktivera alternativen nedan för att tillåta Quick Match att överskriva befintliga omslag och/eller metadata.",
|
"MessageBatchQuickMatchDescription": "Quick Match kommer försöka lägga till saknade omslag och metadata för de valda föremålen. Aktivera alternativen nedan för att tillåta Quick Match att överskriva befintliga omslag och/eller metadata.",
|
||||||
"MessageBookshelfNoCollections": "Du har ännu inte skapat några samlingar",
|
"MessageBookshelfNoCollections": "Du har ännu inte skapat några samlingar",
|
||||||
"MessageBookshelfNoRSSFeeds": "Inga RSS-flöden är öppna",
|
"MessageBookshelfNoRSSFeeds": "Inga RSS-flöden är öppna",
|
||||||
"MessageBookshelfNoResultsForFilter": "Inga resultat för filter \"{0}: {1}\"",
|
"MessageBookshelfNoResultsForFilter": "Inga resultat för filter \"{0}: {1}\"",
|
||||||
|
"MessageBookshelfNoResultsForQuery": "Sökningen gav inget resultat",
|
||||||
"MessageBookshelfNoSeries": "Du har inga serier",
|
"MessageBookshelfNoSeries": "Du har inga serier",
|
||||||
"MessageChapterEndIsAfter": "Kapitelns slut är efter din ljudboks slut",
|
"MessageChapterEndIsAfter": "Kapitelns slut är efter din ljudboks slut",
|
||||||
"MessageChapterErrorFirstNotZero": "Första kapitlet måste börja vid 0",
|
"MessageChapterErrorFirstNotZero": "Första kapitlet måste börja vid 0",
|
||||||
"MessageChapterErrorStartGteDuration": "Ogiltig starttid måste vara mindre än ljudbokens varaktighet",
|
"MessageChapterErrorStartGteDuration": "Ogiltig starttid, måste vara mindre än ljudbokens varaktighet",
|
||||||
"MessageChapterErrorStartLtPrev": "Ogiltig starttid måste vara större än eller lika med tidigare kapitels starttid",
|
"MessageChapterErrorStartLtPrev": "Ogiltig starttid, måste vara större än eller lika med föregående kapitlets starttid",
|
||||||
"MessageChapterStartIsAfter": "Kapitlets start är efter din ljudboks slut",
|
"MessageChapterStartIsAfter": "Kapitlets start är efter din ljudboks slut",
|
||||||
"MessageCheckingCron": "Kontrollerar cron...",
|
"MessageCheckingCron": "Kontrollerar cron...",
|
||||||
"MessageConfirmCloseFeed": "Är du säker på att du vill stänga detta flöde?",
|
"MessageConfirmCloseFeed": "Är du säker på att du vill stänga detta flöde?",
|
||||||
"MessageConfirmDeleteBackup": "Är du säker på att du vill radera säkerhetskopian för {0}?",
|
"MessageConfirmDeleteBackup": "Är du säker på att du vill radera säkerhetskopian för {0}?",
|
||||||
|
"MessageConfirmDeleteDevice": "Är du säkert på att du vill radera enheten för e-böcker \"{0}\"?",
|
||||||
"MessageConfirmDeleteFile": "Detta kommer att radera filen från ditt filsystem. Är du säker?",
|
"MessageConfirmDeleteFile": "Detta kommer att radera filen från ditt filsystem. Är du säker?",
|
||||||
"MessageConfirmDeleteLibrary": "Är du säker på att du vill radera biblioteket \"{0}\"?",
|
"MessageConfirmDeleteLibrary": "Är du säker på att du vill radera biblioteket '{0}'?",
|
||||||
"MessageConfirmDeleteLibraryItem": "Detta kommer att radera biblioteksföremålet från databasen och ditt filsystem. Är du säker?",
|
"MessageConfirmDeleteLibraryItem": "Detta kommer att radera biblioteksobjektet från databasen och ditt filsystem. Är du säker?",
|
||||||
"MessageConfirmDeleteLibraryItems": "Detta kommer att radera {0} biblioteksföremål från databasen och ditt filsystem. Är du säker?",
|
"MessageConfirmDeleteLibraryItems": "Detta kommer att radera {0} biblioteksobjekt från databasen och ditt filsystem. Är du säker?",
|
||||||
"MessageConfirmDeleteSession": "Är du säker på att du vill radera denna session?",
|
"MessageConfirmDeleteMetadataProvider": "Är du säker på att du vill radera din egen källa för metadata \"{0}\"?",
|
||||||
|
"MessageConfirmDeleteSession": "Är du säker på att du vill radera detta lyssningstillfälle?",
|
||||||
"MessageConfirmForceReScan": "Är du säker på att du vill tvinga omgenomsökning?",
|
"MessageConfirmForceReScan": "Är du säker på att du vill tvinga omgenomsökning?",
|
||||||
"MessageConfirmMarkAllEpisodesFinished": "Är du säker på att du vill markera alla avsnitt som avslutade?",
|
"MessageConfirmMarkAllEpisodesFinished": "Är du säker på att du vill markera alla avsnitt som avslutade?",
|
||||||
"MessageConfirmMarkAllEpisodesNotFinished": "Är du säker på att du vill markera alla avsnitt som inte avslutade?",
|
"MessageConfirmMarkAllEpisodesNotFinished": "Är du säker på att du vill markera alla avsnitt som ej avslutade?",
|
||||||
|
"MessageConfirmMarkItemFinished": "Är du säker på att du vill markera \"{0}\" som avslutad?",
|
||||||
|
"MessageConfirmMarkItemNotFinished": "Är du säker på att du vill markera \"{0}\" som ej avslutad?",
|
||||||
"MessageConfirmMarkSeriesFinished": "Är du säker på att du vill markera alla böcker i denna serie som avslutade?",
|
"MessageConfirmMarkSeriesFinished": "Är du säker på att du vill markera alla böcker i denna serie som avslutade?",
|
||||||
"MessageConfirmMarkSeriesNotFinished": "Är du säker på att du vill markera alla böcker i denna serie som ej avslutade?",
|
"MessageConfirmMarkSeriesNotFinished": "Är du säker på att du vill markera alla böcker i denna serie som ej avslutade?",
|
||||||
|
"MessageConfirmPurgeCache": "När du rensar cashen kommer katalogen <code>/metadata/cache</code> att raderas. <br /><br />Är du säker på att du vill radera katalogen?",
|
||||||
|
"MessageConfirmPurgeItemsCache": "När du rensar cashen för föremål kommer katalogen <code>/metadata/cache/items</code> att raderas. <br /><br />Är du säker på att du vill radera katalogen?",
|
||||||
"MessageConfirmQuickEmbed": "VARNING! Quick embed kommer inte att säkerhetskopiera dina ljudfiler. Se till att du har en säkerhetskopia av dina ljudfiler. <br><br>Vill du fortsätta?",
|
"MessageConfirmQuickEmbed": "VARNING! Quick embed kommer inte att säkerhetskopiera dina ljudfiler. Se till att du har en säkerhetskopia av dina ljudfiler. <br><br>Vill du fortsätta?",
|
||||||
"MessageConfirmReScanLibraryItems": "Är du säker på att du vill göra omgenomsökning för {0} objekt?",
|
"MessageConfirmReScanLibraryItems": "Är du säker på att du vill göra en ny genomsökning för {0} objekt?",
|
||||||
"MessageConfirmRemoveAllChapters": "Är du säker på att du vill ta bort alla kapitel?",
|
"MessageConfirmRemoveAllChapters": "Är du säker på att du vill ta bort alla kapitel?",
|
||||||
"MessageConfirmRemoveAuthor": "Är du säker på att du vill ta bort författaren \"{0}\"?",
|
"MessageConfirmRemoveAuthor": "Är du säker på att du vill ta bort författaren \"{0}\"?",
|
||||||
"MessageConfirmRemoveCollection": "Är du säker på att du vill ta bort samlingen \"{0}\"?",
|
"MessageConfirmRemoveCollection": "Är du säker på att du vill ta bort samlingen \"{0}\"?",
|
||||||
"MessageConfirmRemoveEpisode": "Är du säker på att du vill ta bort avsnittet \"{0}\"?",
|
"MessageConfirmRemoveEpisode": "Är du säker på att du vill ta bort avsnittet \"{0}\"?",
|
||||||
"MessageConfirmRemoveEpisodes": "Är du säker på att du vill ta bort {0} avsnitt?",
|
"MessageConfirmRemoveEpisodes": "Är du säker på att du vill ta bort {0} avsnitt?",
|
||||||
|
"MessageConfirmRemoveListeningSessions": "Är du säker på att du vill radera {0} lyssningstillfällen?",
|
||||||
|
"MessageConfirmRemoveMetadataFiles": "Är du säker på att du vill radera 'metadata.{0}' filerna i alla mappar i ditt bibliotek?",
|
||||||
"MessageConfirmRemoveNarrator": "Är du säker på att du vill ta bort uppläsaren \"{0}\"?",
|
"MessageConfirmRemoveNarrator": "Är du säker på att du vill ta bort uppläsaren \"{0}\"?",
|
||||||
"MessageConfirmRemovePlaylist": "Är du säker på att du vill ta bort din spellista \"{0}\"?",
|
"MessageConfirmRemovePlaylist": "Är du säker på att du vill ta bort din spellista \"{0}\"?",
|
||||||
"MessageConfirmRenameGenre": "Är du säker på att du vill byta namn på kategori \"{0}\" till \"{1}\" för alla objekt?",
|
"MessageConfirmRenameGenre": "Är du säker på att du vill byta namn på kategorin \"{0}\" till \"{1}\" för alla objekt?",
|
||||||
"MessageConfirmRenameGenreMergeNote": "OBS: Den här kategorin finns redan, så de kommer att slås samman.",
|
"MessageConfirmRenameGenreMergeNote": "OBS: Den här kategorin finns redan, så de kommer att slås samman.",
|
||||||
"MessageConfirmRenameGenreWarning": "Varning! En liknande kategori med annat skrivsätt finns redan \"{0}\".",
|
"MessageConfirmRenameGenreWarning": "Varning! En liknande kategori med annat skrivsätt finns redan \"{0}\".",
|
||||||
"MessageConfirmRenameTag": "Är du säker på att du vill byta namn på taggen \"{0}\" till \"{1}\" för alla objekt?",
|
"MessageConfirmRenameTag": "Är du säker på att du vill byta namn på taggen \"{0}\" till \"{1}\" för alla objekt?",
|
||||||
"MessageConfirmRenameTagMergeNote": "OBS: Den här taggen finns redan, så de kommer att slås samman.",
|
"MessageConfirmRenameTagMergeNote": "OBS: Den här taggen finns redan, så de kommer att slås samman.",
|
||||||
"MessageConfirmRenameTagWarning": "VARNING! En liknande tagg med annat skrivsätt finns redan \"{0}\".",
|
"MessageConfirmRenameTagWarning": "VARNING! En liknande tagg med annat skrivsätt finns redan \"{0}\".",
|
||||||
|
"MessageConfirmResetProgress": "Är du säker på att du vill nollställa ditt framsteg?",
|
||||||
"MessageConfirmSendEbookToDevice": "Är du säker på att du vill skicka {0} e-bok \"{1}\" till enheten \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "Är du säker på att du vill skicka {0} e-bok \"{1}\" till enheten \"{2}\"?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} dagars lyssnande det senaste året",
|
||||||
"MessageDownloadingEpisode": "Laddar ner avsnitt",
|
"MessageDownloadingEpisode": "Laddar ner avsnitt",
|
||||||
"MessageDragFilesIntoTrackOrder": "Dra filer till rätt spårordning",
|
"MessageDragFilesIntoTrackOrder": "Dra filer till rätt spårordning",
|
||||||
"MessageEmbedFinished": "Inbäddning klar!",
|
"MessageEmbedFinished": "Inbäddning genomförd!",
|
||||||
"MessageEpisodesQueuedForDownload": "{0} avsnitt i kö för nedladdning",
|
"MessageEpisodesQueuedForDownload": "{0} avsnitt i kö för nedladdning",
|
||||||
|
"MessageEreaderDevices": "För att säkerställa överföring av e-böcker kan du bli tvungen<br>att addera ovanstående e-postadress som godkänd<br>avsändare för varje enhet angiven nedan.",
|
||||||
"MessageFeedURLWillBe": "Flödes-URL kommer att vara {0}",
|
"MessageFeedURLWillBe": "Flödes-URL kommer att vara {0}",
|
||||||
"MessageFetching": "Hämtar...",
|
"MessageFetching": "Hämtar...",
|
||||||
"MessageForceReScanDescription": "kommer att göra en omgångssökning av alla filer som en färsk sökning. ID3-taggar för ljudfiler, OPF-filer och textfiler kommer att sökas som nya.",
|
"MessageForceReScanDescription": "kommer att göra en omgångssökning av alla filer som en färsk sökning. ID3-taggar för ljudfiler, OPF-filer och textfiler kommer att sökas som nya.",
|
||||||
@ -592,22 +694,24 @@
|
|||||||
"MessageJoinUsOn": "Anslut dig till oss på",
|
"MessageJoinUsOn": "Anslut dig till oss på",
|
||||||
"MessageLoading": "Laddar...",
|
"MessageLoading": "Laddar...",
|
||||||
"MessageLoadingFolders": "Laddar mappar...",
|
"MessageLoadingFolders": "Laddar mappar...",
|
||||||
|
"MessageLogsDescription": "Filer med loggar sparas i mappen <code>/metadata/logs</code> som JSON-filer.<br>Filer med information om krascher sparas i <code>/metadata/logs/crash_logs.txt</code>.",
|
||||||
"MessageM4BFailed": "M4B misslyckades!",
|
"MessageM4BFailed": "M4B misslyckades!",
|
||||||
"MessageM4BFinished": "M4B klar!",
|
"MessageM4BFinished": "M4B klar!",
|
||||||
"MessageMapChapterTitles": "Kartlägg kapitelrubriker till dina befintliga ljudbokskapitel utan att justera tidstämplar",
|
"MessageMapChapterTitles": "Kartlägg kapitelrubriker till dina befintliga ljudbokskapitel utan att justera tidstämplar",
|
||||||
"MessageMarkAllEpisodesFinished": "Markera alla avsnitt som avslutade",
|
"MessageMarkAllEpisodesFinished": "Markera alla avsnitt som avslutade",
|
||||||
"MessageMarkAllEpisodesNotFinished": "Markera alla avsnitt som inte avslutade",
|
"MessageMarkAllEpisodesNotFinished": "Markera alla avsnitt som ej avslutade",
|
||||||
"MessageMarkAsFinished": "Markera som avslutad",
|
"MessageMarkAsFinished": "Markera som avslutad",
|
||||||
"MessageMarkAsNotFinished": "Markera som inte avslutad",
|
"MessageMarkAsNotFinished": "Markera som ej avslutad",
|
||||||
"MessageMatchBooksDescription": "kommer att försöka matcha böcker i biblioteket med en bok från den valda källan och fylla i uppgifter som saknas och bokomslag. Inga befintliga uppgifter kommer att ersättas.",
|
"MessageMatchBooksDescription": "kommer att försöka matcha böcker i biblioteket med en bok från<br>den valda källan och fylla i uppgifter som saknas och bokomslag.<br>Inga befintliga uppgifter kommer att ersättas.",
|
||||||
"MessageNoAudioTracks": "Inga ljudspår",
|
"MessageNoAudioTracks": "Inga ljudspår",
|
||||||
"MessageNoAuthors": "Inga författare",
|
"MessageNoAuthors": "Inga författare",
|
||||||
"MessageNoBackups": "Inga säkerhetskopior",
|
"MessageNoBackups": "Inga säkerhetskopior",
|
||||||
"MessageNoBookmarks": "Inga bokmärken",
|
"MessageNoBookmarks": "Inga bokmärken",
|
||||||
"MessageNoChapters": "Inga kapitel",
|
"MessageNoChapters": "Inga kapitel",
|
||||||
"MessageNoCollections": "Inga samlingar",
|
"MessageNoCollections": "Inga samlingar",
|
||||||
"MessageNoCoversFound": "Inga omslag hittade",
|
"MessageNoCoversFound": "Inga bokomslag hittades",
|
||||||
"MessageNoDescription": "Ingen beskrivning",
|
"MessageNoDescription": "Ingen beskrivning",
|
||||||
|
"MessageNoDevices": "Inga enheter angivna",
|
||||||
"MessageNoDownloadsInProgress": "Inga nedladdningar pågår för närvarande",
|
"MessageNoDownloadsInProgress": "Inga nedladdningar pågår för närvarande",
|
||||||
"MessageNoDownloadsQueued": "Inga nedladdningar i kö",
|
"MessageNoDownloadsQueued": "Inga nedladdningar i kö",
|
||||||
"MessageNoEpisodeMatchesFound": "Inga matchande avsnitt hittades",
|
"MessageNoEpisodeMatchesFound": "Inga matchande avsnitt hittades",
|
||||||
@ -617,7 +721,7 @@
|
|||||||
"MessageNoIssues": "Inga problem",
|
"MessageNoIssues": "Inga problem",
|
||||||
"MessageNoItems": "Inga objekt",
|
"MessageNoItems": "Inga objekt",
|
||||||
"MessageNoItemsFound": "Inga objekt hittades",
|
"MessageNoItemsFound": "Inga objekt hittades",
|
||||||
"MessageNoListeningSessions": "Inga lyssningssessioner",
|
"MessageNoListeningSessions": "Inga lyssningstillfällen",
|
||||||
"MessageNoLogs": "Inga loggar",
|
"MessageNoLogs": "Inga loggar",
|
||||||
"MessageNoMediaProgress": "Ingen medieförlopp",
|
"MessageNoMediaProgress": "Ingen medieförlopp",
|
||||||
"MessageNoNotifications": "Inga aviseringar",
|
"MessageNoNotifications": "Inga aviseringar",
|
||||||
@ -634,51 +738,67 @@
|
|||||||
"MessagePauseChapter": "Pausa kapiteluppspelning",
|
"MessagePauseChapter": "Pausa kapiteluppspelning",
|
||||||
"MessagePlayChapter": "Lyssna på kapitlets början",
|
"MessagePlayChapter": "Lyssna på kapitlets början",
|
||||||
"MessagePlaylistCreateFromCollection": "Skapa spellista från samling",
|
"MessagePlaylistCreateFromCollection": "Skapa spellista från samling",
|
||||||
|
"MessagePleaseWait": "Vänta ett ögonblick...",
|
||||||
"MessagePodcastHasNoRSSFeedForMatching": "Podcasten har ingen RSS-flödes-URL att använda för matchning",
|
"MessagePodcastHasNoRSSFeedForMatching": "Podcasten har ingen RSS-flödes-URL att använda för matchning",
|
||||||
"MessageQuickMatchDescription": "Fyll tomma objektdetaljer och omslag med första matchningsresultat från '{0}'. Överskriver inte detaljer om inte serverinställningen 'Föredra matchad metadata' är aktiverad.",
|
"MessageQuickMatchDescription": "Adderar uppgifter som saknas samt en omslagsbild från<br>första träffen i resultatet vid sökningen från '{0}'.<br>Skriver inte över befintliga uppgifter om inte<br>inställningen 'Prioritera matchad metadata' är aktiverad.",
|
||||||
"MessageRemoveChapter": "Ta bort kapitel",
|
"MessageRemoveChapter": "Ta bort kapitel",
|
||||||
"MessageRemoveEpisodes": "Ta bort {0} avsnitt",
|
"MessageRemoveEpisodes": "Ta bort {0} avsnitt",
|
||||||
"MessageRemoveFromPlayerQueue": "Ta bort från spellistan",
|
"MessageRemoveFromPlayerQueue": "Ta bort från spellistan",
|
||||||
"MessageRemoveUserWarning": "Är du säker på att du vill radera användaren \"{0}\" permanent?",
|
"MessageRemoveUserWarning": "Är du säker på att du vill radera användaren \"{0}\"?",
|
||||||
"MessageReportBugsAndContribute": "Rapportera buggar, begär funktioner och bidra på",
|
"MessageReportBugsAndContribute": "Rapportera buggar, begär funktioner och bidra på",
|
||||||
"MessageResetChaptersConfirm": "Är du säker på att du vill återställa kapitel och ångra ändringarna du gjort?",
|
"MessageResetChaptersConfirm": "Är du säker på att du vill återställa alla kapitel och ångra de ändringarna du gjort?",
|
||||||
"MessageRestoreBackupConfirm": "Är du säker på att du vill återställa säkerhetskopian som skapades den",
|
"MessageRestoreBackupConfirm": "Är du säker på att du vill läsa in säkerhetskopian som skapades den",
|
||||||
"MessageRestoreBackupWarning": "Att återställa en säkerhetskopia kommer att skriva över hela databasen som finns i /config och omslagsbilder i /metadata/items & /metadata/authors.<br /><br />Säkerhetskopior ändrar inte några filer i dina biblioteksmappar. Om du har aktiverat serverinställningar för att lagra omslagskonst och metadata i dina biblioteksmappar säkerhetskopieras eller skrivs de inte över.<br /><br />Alla klienter som använder din server kommer att uppdateras automatiskt.",
|
"MessageRestoreBackupWarning": "Att återställa en säkerhetskopia kommer att skriva över hela databasen som finns i /config och omslagsbilder i /metadata/items & /metadata/authors.<br /><br />Säkerhetskopior ändrar inte några filer i dina biblioteksmappar. Om du har aktiverat serverinställningar för att lagra omslagskonst och metadata i dina biblioteksmappar säkerhetskopieras eller skrivs de inte över.<br /><br />Alla klienter som använder din server kommer att uppdateras automatiskt.",
|
||||||
"MessageSearchResultsFor": "Sökresultat för",
|
"MessageSearchResultsFor": "Sökresultat för",
|
||||||
|
"MessageSelected": "{0} valda",
|
||||||
"MessageServerCouldNotBeReached": "Servern kunde inte nås",
|
"MessageServerCouldNotBeReached": "Servern kunde inte nås",
|
||||||
"MessageSetChaptersFromTracksDescription": "Ställ in kapitel med varje ljudfil som ett kapitel och kapitelrubrik som ljudfilens namn",
|
"MessageSetChaptersFromTracksDescription": "Ställ in kapitel med varje ljudfil som ett kapitel och kapitelrubrik som ljudfilens namn",
|
||||||
"MessageStartPlaybackAtTime": "Starta uppspelning för \"{0}\" kl. {1}?",
|
"MessageStartPlaybackAtTime": "Starta uppspelning av \"{0}\" vid tidpunkt {1}?",
|
||||||
|
"MessageTaskCanceledByUser": "Uppgiften avslutades av användaren",
|
||||||
|
"MessageTaskFailed": "Misslyckades",
|
||||||
|
"MessageTaskFailedToCreateCacheDirectory": "Misslyckades med att skapa bibliotek för cachen",
|
||||||
|
"MessageTaskMatchingBooksInLibrary": "Matchar böcker i biblioteket \"{0}\"",
|
||||||
"MessageThinking": "Tänker...",
|
"MessageThinking": "Tänker...",
|
||||||
"MessageUploaderItemFailed": "Misslyckades med att ladda upp",
|
"MessageUploaderItemFailed": "Misslyckades med att ladda upp",
|
||||||
"MessageUploaderItemSuccess": "Uppladdning lyckades!",
|
"MessageUploaderItemSuccess": "Uppladdning lyckades!",
|
||||||
"MessageUploading": "Laddar upp...",
|
"MessageUploading": "Laddar upp...",
|
||||||
"MessageValidCronExpression": "Giltigt cron-uttryck",
|
"MessageValidCronExpression": "Giltigt cron-uttryck",
|
||||||
"MessageWatcherIsDisabledGlobally": "Vakten är inaktiverad globalt i serverinställningarna",
|
"MessageWatcherIsDisabledGlobally": "Watcher är inaktiverad centralt under rubriken 'Inställningar'",
|
||||||
"MessageXLibraryIsEmpty": "{0} biblioteket är tomt!",
|
"MessageXLibraryIsEmpty": "Biblioteket {0} är tomt!",
|
||||||
"MessageYourAudiobookDurationIsLonger": "Varaktigheten på din ljudbok är längre än den hittade varaktigheten",
|
"MessageYourAudiobookDurationIsLonger": "Varaktigheten på din ljudbok är längre än den hittade varaktigheten",
|
||||||
"MessageYourAudiobookDurationIsShorter": "Varaktigheten på din ljudbok är kortare än den hittade varaktigheten",
|
"MessageYourAudiobookDurationIsShorter": "Varaktigheten på din ljudbok är kortare än den hittade varaktigheten",
|
||||||
"NoteChangeRootPassword": "Rotanvändaren är den enda användaren som kan ha ett tomt lösenord",
|
"NoteChangeRootPassword": "Rotanvändaren är den enda användaren som kan ha ett tomt lösenord",
|
||||||
"NoteChapterEditorTimes": "Obs: Starttiden för första kapitlet måste förbli 0:00 och starttiden för det sista kapitlet får inte överstiga ljudbokens varaktighet.",
|
"NoteChapterEditorTimes": "OBS: Starttiden för första kapitlet måste vara 0:00 och starttiden för det sista kapitlet får inte överstiga ljudbokens totala varaktighet.",
|
||||||
"NoteFolderPicker": "Obs: Mappar som redan är kartlagda kommer inte att visas",
|
"NoteFolderPicker": "Obs: Mappar som redan är kartlagda kommer inte att visas",
|
||||||
"NoteRSSFeedPodcastAppsHttps": "Varning: De flesta podcastappar kräver att RSS-flödets URL används med HTTPS",
|
"NoteRSSFeedPodcastAppsHttps": "Varning: De flesta podcastappar kräver att RSS-flödets URL används med HTTPS",
|
||||||
"NoteRSSFeedPodcastAppsPubDate": "Varning: 1 eller flera av dina avsnitt har inte ett publiceringsdatum. Vissa podcastappar kräver detta.",
|
"NoteRSSFeedPodcastAppsPubDate": "Varning: 1 eller flera av dina avsnitt har inte ett publiceringsdatum. Vissa podcastappar kräver detta.",
|
||||||
"NoteUploaderFoldersWithMediaFiles": "Mappar med flera mediefiler hanteras som separata objekt i biblioteket.",
|
"NoteUploaderFoldersWithMediaFiles": "Mappar med flera mediefiler hanteras som separata objekt i biblioteket.",
|
||||||
"NoteUploaderOnlyAudioFiles": "Om du bara laddar upp ljudfiler kommer varje ljudfil att hanteras som en separat ljudbok.",
|
"NoteUploaderOnlyAudioFiles": "<br>Om du bara laddar upp ljudfiler kommer varje ljudfil att hanteras som en separat ljudbok.",
|
||||||
"NoteUploaderUnsupportedFiles": "Oaccepterade filer ignoreras. När du väljer eller släpper en mapp ignoreras andra filer som inte finns i ett objektmapp.",
|
"NoteUploaderUnsupportedFiles": "Oaccepterade filer ignoreras. När du väljer eller släpper en mapp ignoreras andra filer som inte finns i ett objektmapp.",
|
||||||
"PlaceholderNewCollection": "Nytt samlingsnamn",
|
"PlaceholderNewCollection": "Nytt samlingsnamn",
|
||||||
"PlaceholderNewFolderPath": "Nytt mappväg",
|
"PlaceholderNewFolderPath": "Nytt sökväg till mappen",
|
||||||
"PlaceholderNewPlaylist": "Nytt spellistanamn",
|
"PlaceholderNewPlaylist": "Nytt namn på spellistan",
|
||||||
"PlaceholderSearch": "Sök...",
|
"PlaceholderSearch": "Sök...",
|
||||||
"PlaceholderSearchEpisode": "Sök avsnitt...",
|
"PlaceholderSearchEpisode": "Sök avsnitt...",
|
||||||
"StatsTopAuthor": "POPULÄRAST FÖRFATTAREN",
|
"StatsAuthorsAdded": "författare har adderats",
|
||||||
"StatsTopAuthors": "POPULÄRASTE FÖRFATTARNA",
|
"StatsBooksAdded": "böcker har adderats",
|
||||||
"StatsTopGenre": "Populäraste kategorin",
|
"StatsBooksAdditional": "Några exempel på det som adderats…",
|
||||||
|
"StatsBooksFinished": "avslutade böcker",
|
||||||
|
"StatsBooksFinishedThisYear": "Några böcker som avslutats under året…",
|
||||||
|
"StatsBooksListenedTo": "böcker, lyssnat på",
|
||||||
|
"StatsCollectionGrewTo": "Ditt biblioteks storlek ökade till…",
|
||||||
|
"StatsSessions": "lyssningstillfällen",
|
||||||
|
"StatsSpentListening": "tid, som lyssnats",
|
||||||
|
"StatsTopAuthor": "Populäraste författare",
|
||||||
|
"StatsTopAuthors": "Populäraste författarna",
|
||||||
|
"StatsTopGenre": "Populäraste kategori",
|
||||||
"StatsTopGenres": "Populäraste kategorierna",
|
"StatsTopGenres": "Populäraste kategorierna",
|
||||||
"StatsTopMonth": "Bästa månaden",
|
"StatsTopMonth": "Bästa månad",
|
||||||
"StatsTopNarrator": "Populärast uppläsarna",
|
"StatsTopNarrator": "Populäraste uppläsare",
|
||||||
"StatsTopNarrators": "Populäraste uppläsaren",
|
"StatsTopNarrators": "Populäraste uppläsarna",
|
||||||
"StatsYearInReview": "SAMMANSTÄLLNING AV ÅRET",
|
"StatsTotalDuration": "Med en total varaktighet…",
|
||||||
"ToastAccountUpdateSuccess": "Kontot uppdaterat",
|
"StatsYearInReview": "- SAMMANSTÄLLNING AV ÅRET",
|
||||||
|
"ToastAccountUpdateSuccess": "Kontot har uppdaterats",
|
||||||
"ToastAsinRequired": "En ASIN-kod krävs",
|
"ToastAsinRequired": "En ASIN-kod krävs",
|
||||||
"ToastAuthorImageRemoveSuccess": "Författarens bild borttagen",
|
"ToastAuthorImageRemoveSuccess": "Författarens bild borttagen",
|
||||||
"ToastAuthorNotFound": "Författaren \"{0}\" kunde inte identifieras",
|
"ToastAuthorNotFound": "Författaren \"{0}\" kunde inte identifieras",
|
||||||
@ -701,43 +821,77 @@
|
|||||||
"ToastBookmarkCreateFailed": "Det gick inte att skapa bokmärket",
|
"ToastBookmarkCreateFailed": "Det gick inte att skapa bokmärket",
|
||||||
"ToastBookmarkCreateSuccess": "Bokmärket har adderats",
|
"ToastBookmarkCreateSuccess": "Bokmärket har adderats",
|
||||||
"ToastBookmarkRemoveSuccess": "Bokmärket har raderats",
|
"ToastBookmarkRemoveSuccess": "Bokmärket har raderats",
|
||||||
"ToastBookmarkUpdateSuccess": "Bokmärket har uppdaterats",
|
"ToastCachePurgeFailed": "Misslyckades med att rensa cachen",
|
||||||
|
"ToastCachePurgeSuccess": "Rensning av cachen har genomförts",
|
||||||
"ToastChaptersHaveErrors": "Kapitlen har fel",
|
"ToastChaptersHaveErrors": "Kapitlen har fel",
|
||||||
"ToastChaptersMustHaveTitles": "Kapitel måste ha titlar",
|
"ToastChaptersMustHaveTitles": "Kapitel måste ha titlar",
|
||||||
"ToastCollectionRemoveSuccess": "Samlingen har raderats",
|
"ToastCollectionRemoveSuccess": "Samlingen har raderats",
|
||||||
"ToastCollectionUpdateSuccess": "Samlingen har uppdaterats",
|
"ToastCollectionUpdateSuccess": "Samlingen har uppdaterats",
|
||||||
"ToastItemCoverUpdateSuccess": "Objektets omslag uppdaterat",
|
"ToastCoverUpdateFailed": "Uppdatering av bokomslag misslyckades",
|
||||||
"ToastItemDetailsUpdateSuccess": "Objektdetaljer uppdaterade",
|
"ToastDateTimeInvalidOrIncomplete": "Datum och klockslag är felaktigt eller ej komplett",
|
||||||
"ToastItemMarkedAsFinishedFailed": "Misslyckades med att markera som färdig",
|
"ToastDeleteFileFailed": "Misslyckades att radera filen",
|
||||||
"ToastItemMarkedAsFinishedSuccess": "Objekt markerat som färdig",
|
"ToastDeleteFileSuccess": "Filen har raderats",
|
||||||
"ToastItemMarkedAsNotFinishedFailed": "Misslyckades med att markera som ej färdig",
|
"ToastDeviceTestEmailFailed": "Misslyckades med att skicka ett testmail",
|
||||||
"ToastItemMarkedAsNotFinishedSuccess": "Objekt markerat som ej färdig",
|
"ToastDeviceTestEmailSuccess": "Ett testmail har skickats",
|
||||||
|
"ToastEmailSettingsUpdateSuccess": "Inställningarna av e-post har uppdaterats",
|
||||||
|
"ToastFailedToLoadData": "Misslyckades med att ladda data",
|
||||||
|
"ToastInvalidImageUrl": "Felaktig URL-adress till omslagsbilden",
|
||||||
|
"ToastInvalidMaxEpisodesToDownload": "Ogiltigt maximalt antal avsnitt att ladda ner",
|
||||||
|
"ToastInvalidUrl": "Felaktig URL-adress",
|
||||||
|
"ToastItemCoverUpdateSuccess": "Objektets bokomslag har uppdaterats",
|
||||||
|
"ToastItemDetailsUpdateSuccess": "Detaljerna om boken har uppdaterats",
|
||||||
|
"ToastItemMarkedAsFinishedFailed": "Misslyckades med att markera den som avslutad",
|
||||||
|
"ToastItemMarkedAsFinishedSuccess": "Den har markerat som avslutad",
|
||||||
|
"ToastItemMarkedAsNotFinishedFailed": "Misslyckades med att markera den som ej avslutad",
|
||||||
|
"ToastItemMarkedAsNotFinishedSuccess": "Den har markerats som ej avslutad",
|
||||||
"ToastLibraryCreateFailed": "Det gick inte att skapa biblioteket",
|
"ToastLibraryCreateFailed": "Det gick inte att skapa biblioteket",
|
||||||
"ToastLibraryCreateSuccess": "Biblioteket \"{0}\" skapat",
|
"ToastLibraryCreateSuccess": "Biblioteket \"{0}\" har skapats",
|
||||||
"ToastLibraryDeleteFailed": "Det gick inte att ta bort biblioteket",
|
"ToastLibraryDeleteFailed": "Det gick inte att ta bort biblioteket",
|
||||||
"ToastLibraryDeleteSuccess": "Biblioteket borttaget",
|
"ToastLibraryDeleteSuccess": "Biblioteket borttaget",
|
||||||
"ToastLibraryScanFailedToStart": "Misslyckades med att starta skanningen",
|
"ToastLibraryScanFailedToStart": "Misslyckades med att starta skanningen",
|
||||||
"ToastLibraryScanStarted": "Skanning av biblioteket påbörjad",
|
"ToastLibraryScanStarted": "Skanning av biblioteket påbörjad",
|
||||||
"ToastLibraryUpdateSuccess": "Biblioteket \"{0}\" uppdaterat",
|
"ToastLibraryUpdateSuccess": "Biblioteket \"{0}\" har uppdaterats",
|
||||||
|
"ToastMetadataFilesRemovedError": "Misslyckades med att radera 'metadata.{0}' filerna",
|
||||||
|
"ToastMetadataFilesRemovedNoneFound": "Inga 'metadata.{0}' filer hittades i biblioteket",
|
||||||
|
"ToastMetadataFilesRemovedNoneRemoved": "Inga 'metadata.{0}' filer raderades",
|
||||||
|
"ToastMetadataFilesRemovedSuccess": "{0} 'metadata.{1}' raderades",
|
||||||
|
"ToastNameEmailRequired": "Ett namn och en e-postadress måste anges",
|
||||||
|
"ToastNameRequired": "Ett namn måste anges",
|
||||||
|
"ToastNewUserCreatedFailed": "Misslyckades med att skapa kontot \"{0}\"",
|
||||||
|
"ToastNewUserCreatedSuccess": "Ett nytt konto har skapats",
|
||||||
|
"ToastNoUpdatesNecessary": "Inga uppdateringar var nödvändiga",
|
||||||
"ToastPlaylistCreateFailed": "Det gick inte att skapa spellistan",
|
"ToastPlaylistCreateFailed": "Det gick inte att skapa spellistan",
|
||||||
"ToastPlaylistCreateSuccess": "Spellistan skapad",
|
"ToastPlaylistCreateSuccess": "Spellistan skapad",
|
||||||
"ToastPlaylistRemoveSuccess": "Spellistan borttagen",
|
"ToastPlaylistRemoveSuccess": "Spellistan har tagits bort",
|
||||||
"ToastPlaylistUpdateSuccess": "Spellistan uppdaterad",
|
"ToastPlaylistUpdateSuccess": "Spellistan uppdaterad",
|
||||||
"ToastPodcastCreateFailed": "Misslyckades med att skapa podcasten",
|
"ToastPodcastCreateFailed": "Misslyckades med att skapa podcasten",
|
||||||
"ToastPodcastCreateSuccess": "Podcasten skapad framgångsrikt",
|
"ToastPodcastCreateSuccess": "Podcasten skapad framgångsrikt",
|
||||||
|
"ToastProviderCreatedFailed": "Misslyckades med att addera en källa",
|
||||||
|
"ToastProviderCreatedSuccess": "En ny källa har adderats",
|
||||||
|
"ToastProviderRemoveSuccess": "Källan har tagits bort",
|
||||||
"ToastRSSFeedCloseFailed": "Misslyckades med att stänga RSS-flödet",
|
"ToastRSSFeedCloseFailed": "Misslyckades med att stänga RSS-flödet",
|
||||||
"ToastRSSFeedCloseSuccess": "RSS-flödet stängt",
|
"ToastRSSFeedCloseSuccess": "RSS-flödet stängt",
|
||||||
"ToastRemoveItemFromCollectionFailed": "Misslyckades med att ta bort objektet från samlingen",
|
"ToastRemoveItemFromCollectionFailed": "Misslyckades med att ta bort objektet från samlingen",
|
||||||
"ToastRemoveItemFromCollectionSuccess": "Objektet borttaget från samlingen",
|
"ToastRemoveItemFromCollectionSuccess": "Objektet borttaget från samlingen",
|
||||||
|
"ToastSelectAtLeastOneUser": "Åtminstone en användare måste väljas",
|
||||||
"ToastSendEbookToDeviceFailed": "Misslyckades med att skicka e-boken till enheten",
|
"ToastSendEbookToDeviceFailed": "Misslyckades med att skicka e-boken till enheten",
|
||||||
"ToastSendEbookToDeviceSuccess": "E-boken skickad till enheten \"{0}\"",
|
"ToastSendEbookToDeviceSuccess": "E-boken skickad till enheten \"{0}\"",
|
||||||
"ToastSeriesUpdateFailed": "Uppdateringen av serier misslyckades",
|
"ToastSeriesUpdateFailed": "Uppdateringen av serier misslyckades",
|
||||||
"ToastSeriesUpdateSuccess": "Uppdateringen av serierna lyckades",
|
"ToastSeriesUpdateSuccess": "Uppdateringen av serierna lyckades",
|
||||||
|
"ToastServerSettingsUpdateSuccess": "Inställningarna för servern har uppdaterats",
|
||||||
"ToastSessionDeleteFailed": "Misslyckades med att ta bort sessionen",
|
"ToastSessionDeleteFailed": "Misslyckades med att ta bort sessionen",
|
||||||
"ToastSessionDeleteSuccess": "Sessionen borttagen",
|
"ToastSessionDeleteSuccess": "Sessionen borttagen",
|
||||||
|
"ToastSleepTimerDone": "Timer har stängt av lyssning. Sov gott... zZzzZz",
|
||||||
"ToastSocketConnected": "Socket ansluten",
|
"ToastSocketConnected": "Socket ansluten",
|
||||||
"ToastSocketDisconnected": "Socket frånkopplad",
|
"ToastSocketDisconnected": "Socket frånkopplad",
|
||||||
"ToastSocketFailedToConnect": "Socket misslyckades med att ansluta",
|
"ToastSocketFailedToConnect": "Socket misslyckades med att ansluta",
|
||||||
|
"ToastSortingPrefixesEmptyError": "Åtminstone ett sorteringsbegrepp måste anges",
|
||||||
|
"ToastSortingPrefixesUpdateSuccess": "{0} begrepp för sortering har uppdateras",
|
||||||
|
"ToastTitleRequired": "En titel måste anges",
|
||||||
|
"ToastUnknownError": "Ett okänt fel inträffade",
|
||||||
"ToastUserDeleteFailed": "Misslyckades med att ta bort användaren",
|
"ToastUserDeleteFailed": "Misslyckades med att ta bort användaren",
|
||||||
"ToastUserDeleteSuccess": "Användaren borttagen"
|
"ToastUserDeleteSuccess": "Användaren borttagen",
|
||||||
|
"ToastUserPasswordChangeSuccess": "Lösenordet har ändrats",
|
||||||
|
"ToastUserPasswordMismatch": "Lösenorden är inte identiska",
|
||||||
|
"ToastUserPasswordMustChange": "Det nya lösenordet kan inte vara samma som det gamla"
|
||||||
}
|
}
|
||||||
|
@ -51,7 +51,7 @@
|
|||||||
"ButtonNext": "Наступний",
|
"ButtonNext": "Наступний",
|
||||||
"ButtonNextChapter": "Наступна глава",
|
"ButtonNextChapter": "Наступна глава",
|
||||||
"ButtonNextItemInQueue": "Наступний елемент у черзі",
|
"ButtonNextItemInQueue": "Наступний елемент у черзі",
|
||||||
"ButtonOk": "Гаразд",
|
"ButtonOk": "Добре",
|
||||||
"ButtonOpenFeed": "Відкрити стрічку",
|
"ButtonOpenFeed": "Відкрити стрічку",
|
||||||
"ButtonOpenManager": "Відкрити менеджер",
|
"ButtonOpenManager": "Відкрити менеджер",
|
||||||
"ButtonPause": "Пауза",
|
"ButtonPause": "Пауза",
|
||||||
@ -463,7 +463,7 @@
|
|||||||
"LabelNotificationsMaxQueueSize": "Ліміт розміру черги сповіщень",
|
"LabelNotificationsMaxQueueSize": "Ліміт розміру черги сповіщень",
|
||||||
"LabelNotificationsMaxQueueSizeHelp": "Події обмежені до 1 на секунду. Події буде проігноровано, якщо ліміт черги досягнуто. Це запобігає спаму сповіщеннями.",
|
"LabelNotificationsMaxQueueSizeHelp": "Події обмежені до 1 на секунду. Події буде проігноровано, якщо ліміт черги досягнуто. Це запобігає спаму сповіщеннями.",
|
||||||
"LabelNumberOfBooks": "Кількість книг",
|
"LabelNumberOfBooks": "Кількість книг",
|
||||||
"LabelNumberOfEpisodes": "Кількість епізодів",
|
"LabelNumberOfEpisodes": "Кількість серій",
|
||||||
"LabelOpenIDAdvancedPermsClaimDescription": "Назва OpenID claim, що містить розширені дозволи на дії користувачів у додатку, які будуть застосовуватися до ролей, що не є адміністраторами (<b>якщо налаштовано</b>). Якщо у відповіді нема claim, у доступі до Audiobookshelf буде відмовлено. Якщо відсутня хоча б одна опція, відповідь буде вважатися <code>хибною</code>. Переконайтеся, що запит постачальника ідентифікаційних даних відповідає очікуваній структурі:",
|
"LabelOpenIDAdvancedPermsClaimDescription": "Назва OpenID claim, що містить розширені дозволи на дії користувачів у додатку, які будуть застосовуватися до ролей, що не є адміністраторами (<b>якщо налаштовано</b>). Якщо у відповіді нема claim, у доступі до Audiobookshelf буде відмовлено. Якщо відсутня хоча б одна опція, відповідь буде вважатися <code>хибною</code>. Переконайтеся, що запит постачальника ідентифікаційних даних відповідає очікуваній структурі:",
|
||||||
"LabelOpenIDClaims": "Не змінюйте наступні параметри, аби вимкнути розширене призначення груп і дозволів, автоматично призначаючи групу 'Користувач'.",
|
"LabelOpenIDClaims": "Не змінюйте наступні параметри, аби вимкнути розширене призначення груп і дозволів, автоматично призначаючи групу 'Користувач'.",
|
||||||
"LabelOpenIDGroupClaimDescription": "Ім'я OpenID claim, що містить список груп користувачів. Зазвичай їх називають <code>групами</code>. <b>Якщо налаштовано</b>, застосунок автоматично призначатиме ролі на основі членства користувача в групах, за умови, що ці групи названі в claim'і без урахування реєстру 'admin', 'user' або 'guest'. Claim мусить містити список, і якщо користувач належить до кількох груп, програма призначить йому роль, що відповідає найвищому рівню доступу. Якщо жодна група не збігається, у доступі буде відмовлено.",
|
"LabelOpenIDGroupClaimDescription": "Ім'я OpenID claim, що містить список груп користувачів. Зазвичай їх називають <code>групами</code>. <b>Якщо налаштовано</b>, застосунок автоматично призначатиме ролі на основі членства користувача в групах, за умови, що ці групи названі в claim'і без урахування реєстру 'admin', 'user' або 'guest'. Claim мусить містити список, і якщо користувач належить до кількох груп, програма призначить йому роль, що відповідає найвищому рівню доступу. Якщо жодна група не збігається, у доступі буде відмовлено.",
|
||||||
@ -758,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "Ви впевнені, що хочете скинути свій прогрес?",
|
"MessageConfirmResetProgress": "Ви впевнені, що хочете скинути свій прогрес?",
|
||||||
"MessageConfirmSendEbookToDevice": "Ви дійсно хочете відправити на пристрій \"{2}\" електроні книги: {0}, \"{1}\"?",
|
"MessageConfirmSendEbookToDevice": "Ви дійсно хочете відправити на пристрій \"{2}\" електроні книги: {0}, \"{1}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "Ви впевнені, що хочете відв'язати цього користувача від OpenID?",
|
"MessageConfirmUnlinkOpenId": "Ви впевнені, що хочете відв'язати цього користувача від OpenID?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "{0} днів, прослуханих за останній рік",
|
||||||
"MessageDownloadingEpisode": "Завантаження епізоду",
|
"MessageDownloadingEpisode": "Завантаження епізоду",
|
||||||
"MessageDragFilesIntoTrackOrder": "Перетягніть файли до правильного порядку",
|
"MessageDragFilesIntoTrackOrder": "Перетягніть файли до правильного порядку",
|
||||||
"MessageEmbedFailed": "Не вдалося вбудувати!",
|
"MessageEmbedFailed": "Не вдалося вбудувати!",
|
||||||
@ -836,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "Ви дійсно бажаєте скинути глави та скасувати внесені зміни?",
|
"MessageResetChaptersConfirm": "Ви дійсно бажаєте скинути глави та скасувати внесені зміни?",
|
||||||
"MessageRestoreBackupConfirm": "Ви дійсно бажаєте відновити резервну копію від",
|
"MessageRestoreBackupConfirm": "Ви дійсно бажаєте відновити резервну копію від",
|
||||||
"MessageRestoreBackupWarning": "Відновлення резервної копії перезапише всю базу даних, розташовану в /config, і зображення обкладинок в /metadata/items та /metadata/authors.<br /><br />Резервні копії не змінюють жодних файлів у теках бібліотеки. Якщо у налаштуваннях сервера увімкнено збереження обкладинок і метаданих у теках бібліотеки, вони не створюються під час резервного копіювання і не перезаписуються..<br /><br />Всі клієнти, що користуються вашим сервером, будуть автоматично оновлені.",
|
"MessageRestoreBackupWarning": "Відновлення резервної копії перезапише всю базу даних, розташовану в /config, і зображення обкладинок в /metadata/items та /metadata/authors.<br /><br />Резервні копії не змінюють жодних файлів у теках бібліотеки. Якщо у налаштуваннях сервера увімкнено збереження обкладинок і метаданих у теках бібліотеки, вони не створюються під час резервного копіювання і не перезаписуються..<br /><br />Всі клієнти, що користуються вашим сервером, будуть автоматично оновлені.",
|
||||||
|
"MessageScheduleLibraryScanNote": "Для більшості користувачів рекомендується залишити цю функцію вимкненою та залишити параметр перегляду папок увімкненим. Засіб спостереження за папками автоматично виявить зміни в папках вашої бібліотеки. Засіб спостереження за папками не працює для кожної файлової системи (наприклад, NFS), тому замість нього можна використовувати сканування бібліотек за розкладом.",
|
||||||
"MessageSearchResultsFor": "Результати пошуку для",
|
"MessageSearchResultsFor": "Результати пошуку для",
|
||||||
"MessageSelected": "Вибрано: {0}",
|
"MessageSelected": "Вибрано: {0}",
|
||||||
"MessageServerCouldNotBeReached": "Не вдалося підключитися до сервера",
|
"MessageServerCouldNotBeReached": "Не вдалося підключитися до сервера",
|
||||||
@ -952,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Не вдалося створити закладку",
|
"ToastBookmarkCreateFailed": "Не вдалося створити закладку",
|
||||||
"ToastBookmarkCreateSuccess": "Закладку додано",
|
"ToastBookmarkCreateSuccess": "Закладку додано",
|
||||||
"ToastBookmarkRemoveSuccess": "Закладку видалено",
|
"ToastBookmarkRemoveSuccess": "Закладку видалено",
|
||||||
"ToastBookmarkUpdateSuccess": "Закладку оновлено",
|
|
||||||
"ToastCachePurgeFailed": "Не вдалося очистити кеш",
|
"ToastCachePurgeFailed": "Не вдалося очистити кеш",
|
||||||
"ToastCachePurgeSuccess": "Кеш очищено",
|
"ToastCachePurgeSuccess": "Кеш очищено",
|
||||||
"ToastChaptersHaveErrors": "Глави містять помилки",
|
"ToastChaptersHaveErrors": "Глави містять помилки",
|
||||||
@ -963,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "Добірку видалено",
|
"ToastCollectionRemoveSuccess": "Добірку видалено",
|
||||||
"ToastCollectionUpdateSuccess": "Добірку оновлено",
|
"ToastCollectionUpdateSuccess": "Добірку оновлено",
|
||||||
"ToastCoverUpdateFailed": "Не вдалося оновити обкладинку",
|
"ToastCoverUpdateFailed": "Не вдалося оновити обкладинку",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "Дата й час недійсні або неповні",
|
||||||
"ToastDeleteFileFailed": "Не вдалося видалити файл",
|
"ToastDeleteFileFailed": "Не вдалося видалити файл",
|
||||||
"ToastDeleteFileSuccess": "Файл видалено",
|
"ToastDeleteFileSuccess": "Файл видалено",
|
||||||
"ToastDeviceAddFailed": "Не вдалося додати пристрій",
|
"ToastDeviceAddFailed": "Не вдалося додати пристрій",
|
||||||
@ -1015,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "Потрібно вибрати хоча б один тег",
|
"ToastNewUserTagError": "Потрібно вибрати хоча б один тег",
|
||||||
"ToastNewUserUsernameError": "Введіть ім'я користувача",
|
"ToastNewUserUsernameError": "Введіть ім'я користувача",
|
||||||
"ToastNoNewEpisodesFound": "Нових епізодів не знайдено",
|
"ToastNoNewEpisodesFound": "Нових епізодів не знайдено",
|
||||||
|
"ToastNoRSSFeed": "Подкаст не має RSS-канал",
|
||||||
"ToastNoUpdatesNecessary": "Оновлення не потрібні",
|
"ToastNoUpdatesNecessary": "Оновлення не потрібні",
|
||||||
"ToastNotificationCreateFailed": "Не вдалося створити сповіщення",
|
"ToastNotificationCreateFailed": "Не вдалося створити сповіщення",
|
||||||
"ToastNotificationDeleteFailed": "Не вдалося видалити сповіщення",
|
"ToastNotificationDeleteFailed": "Не вдалося видалити сповіщення",
|
||||||
|
@ -679,7 +679,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "Tạo đánh dấu thất bại",
|
"ToastBookmarkCreateFailed": "Tạo đánh dấu thất bại",
|
||||||
"ToastBookmarkCreateSuccess": "Đã thêm đánh dấu",
|
"ToastBookmarkCreateSuccess": "Đã thêm đánh dấu",
|
||||||
"ToastBookmarkRemoveSuccess": "Đánh dấu đã được xóa",
|
"ToastBookmarkRemoveSuccess": "Đánh dấu đã được xóa",
|
||||||
"ToastBookmarkUpdateSuccess": "Đánh dấu đã được cập nhật",
|
|
||||||
"ToastChaptersHaveErrors": "Các chương có lỗi",
|
"ToastChaptersHaveErrors": "Các chương có lỗi",
|
||||||
"ToastChaptersMustHaveTitles": "Các chương phải có tiêu đề",
|
"ToastChaptersMustHaveTitles": "Các chương phải có tiêu đề",
|
||||||
"ToastCollectionRemoveSuccess": "Bộ sưu tập đã được xóa",
|
"ToastCollectionRemoveSuccess": "Bộ sưu tập đã được xóa",
|
||||||
|
@ -300,6 +300,7 @@
|
|||||||
"LabelDiscover": "发现",
|
"LabelDiscover": "发现",
|
||||||
"LabelDownload": "下载",
|
"LabelDownload": "下载",
|
||||||
"LabelDownloadNEpisodes": "下载 {0} 集",
|
"LabelDownloadNEpisodes": "下载 {0} 集",
|
||||||
|
"LabelDownloadable": "可下载",
|
||||||
"LabelDuration": "持续时间",
|
"LabelDuration": "持续时间",
|
||||||
"LabelDurationComparisonExactMatch": "(完全匹配)",
|
"LabelDurationComparisonExactMatch": "(完全匹配)",
|
||||||
"LabelDurationComparisonLonger": "({0} 更长)",
|
"LabelDurationComparisonLonger": "({0} 更长)",
|
||||||
@ -588,6 +589,7 @@
|
|||||||
"LabelSettingsStoreMetadataWithItemHelp": "默认情况下元数据文件存储在/metadata/items文件夹中, 启用此设置将存储元数据在你媒体项目文件夹中",
|
"LabelSettingsStoreMetadataWithItemHelp": "默认情况下元数据文件存储在/metadata/items文件夹中, 启用此设置将存储元数据在你媒体项目文件夹中",
|
||||||
"LabelSettingsTimeFormat": "时间格式",
|
"LabelSettingsTimeFormat": "时间格式",
|
||||||
"LabelShare": "分享",
|
"LabelShare": "分享",
|
||||||
|
"LabelShareDownloadableHelp": "允许用户通过共享链接的下载库项目为 zip 文件.",
|
||||||
"LabelShareOpen": "打开分享",
|
"LabelShareOpen": "打开分享",
|
||||||
"LabelShareURL": "分享 URL",
|
"LabelShareURL": "分享 URL",
|
||||||
"LabelShowAll": "全部显示",
|
"LabelShowAll": "全部显示",
|
||||||
@ -756,6 +758,7 @@
|
|||||||
"MessageConfirmResetProgress": "你确定要重置进度吗?",
|
"MessageConfirmResetProgress": "你确定要重置进度吗?",
|
||||||
"MessageConfirmSendEbookToDevice": "你确定要发送 {0} 电子书 \"{1}\" 到设备 \"{2}\"?",
|
"MessageConfirmSendEbookToDevice": "你确定要发送 {0} 电子书 \"{1}\" 到设备 \"{2}\"?",
|
||||||
"MessageConfirmUnlinkOpenId": "你确定要取消该用户与 OpenID 的链接吗?",
|
"MessageConfirmUnlinkOpenId": "你确定要取消该用户与 OpenID 的链接吗?",
|
||||||
|
"MessageDaysListenedInTheLastYear": "去年收听了 {0} 天",
|
||||||
"MessageDownloadingEpisode": "正在下载剧集",
|
"MessageDownloadingEpisode": "正在下载剧集",
|
||||||
"MessageDragFilesIntoTrackOrder": "将文件拖动到正确的音轨顺序",
|
"MessageDragFilesIntoTrackOrder": "将文件拖动到正确的音轨顺序",
|
||||||
"MessageEmbedFailed": "嵌入失败!",
|
"MessageEmbedFailed": "嵌入失败!",
|
||||||
@ -834,6 +837,7 @@
|
|||||||
"MessageResetChaptersConfirm": "你确定要重置章节并撤消你所做的更改吗?",
|
"MessageResetChaptersConfirm": "你确定要重置章节并撤消你所做的更改吗?",
|
||||||
"MessageRestoreBackupConfirm": "你确定要恢复创建的这个备份",
|
"MessageRestoreBackupConfirm": "你确定要恢复创建的这个备份",
|
||||||
"MessageRestoreBackupWarning": "恢复备份将覆盖位于 /config 的整个数据库并覆盖 /metadata/items & /metadata/authors 中的图像.<br /><br />备份不会修改媒体库文件夹中的任何文件. 如果你已启用服务器设置将封面和元数据存储在库文件夹中,则不会备份或覆盖这些内容.<br /><br />将自动刷新使用服务器的所有客户端.",
|
"MessageRestoreBackupWarning": "恢复备份将覆盖位于 /config 的整个数据库并覆盖 /metadata/items & /metadata/authors 中的图像.<br /><br />备份不会修改媒体库文件夹中的任何文件. 如果你已启用服务器设置将封面和元数据存储在库文件夹中,则不会备份或覆盖这些内容.<br /><br />将自动刷新使用服务器的所有客户端.",
|
||||||
|
"MessageScheduleLibraryScanNote": "对于大多数用户, 建议禁用此功能并保持文件夹监视程序设置启用. 文件夹监视程序将自动检测库文件夹中的更改. 文件夹监视程序不适用于每个文件系统 (如 NFS), 因此可以使用计划库扫描.",
|
||||||
"MessageSearchResultsFor": "搜索结果",
|
"MessageSearchResultsFor": "搜索结果",
|
||||||
"MessageSelected": "{0} 已选择",
|
"MessageSelected": "{0} 已选择",
|
||||||
"MessageServerCouldNotBeReached": "无法访问服务器",
|
"MessageServerCouldNotBeReached": "无法访问服务器",
|
||||||
@ -950,7 +954,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "创建书签失败",
|
"ToastBookmarkCreateFailed": "创建书签失败",
|
||||||
"ToastBookmarkCreateSuccess": "书签已添加",
|
"ToastBookmarkCreateSuccess": "书签已添加",
|
||||||
"ToastBookmarkRemoveSuccess": "书签已删除",
|
"ToastBookmarkRemoveSuccess": "书签已删除",
|
||||||
"ToastBookmarkUpdateSuccess": "书签已更新",
|
|
||||||
"ToastCachePurgeFailed": "清除缓存失败",
|
"ToastCachePurgeFailed": "清除缓存失败",
|
||||||
"ToastCachePurgeSuccess": "缓存清除成功",
|
"ToastCachePurgeSuccess": "缓存清除成功",
|
||||||
"ToastChaptersHaveErrors": "章节有错误",
|
"ToastChaptersHaveErrors": "章节有错误",
|
||||||
@ -961,6 +964,7 @@
|
|||||||
"ToastCollectionRemoveSuccess": "收藏夹已删除",
|
"ToastCollectionRemoveSuccess": "收藏夹已删除",
|
||||||
"ToastCollectionUpdateSuccess": "收藏夹已更新",
|
"ToastCollectionUpdateSuccess": "收藏夹已更新",
|
||||||
"ToastCoverUpdateFailed": "封面更新失败",
|
"ToastCoverUpdateFailed": "封面更新失败",
|
||||||
|
"ToastDateTimeInvalidOrIncomplete": "日期和时间无效或不完整",
|
||||||
"ToastDeleteFileFailed": "删除文件失败",
|
"ToastDeleteFileFailed": "删除文件失败",
|
||||||
"ToastDeleteFileSuccess": "文件已删除",
|
"ToastDeleteFileSuccess": "文件已删除",
|
||||||
"ToastDeviceAddFailed": "添加设备失败",
|
"ToastDeviceAddFailed": "添加设备失败",
|
||||||
@ -1013,6 +1017,7 @@
|
|||||||
"ToastNewUserTagError": "必须至少选择一个标签",
|
"ToastNewUserTagError": "必须至少选择一个标签",
|
||||||
"ToastNewUserUsernameError": "输入用户名",
|
"ToastNewUserUsernameError": "输入用户名",
|
||||||
"ToastNoNewEpisodesFound": "没有找到新剧集",
|
"ToastNoNewEpisodesFound": "没有找到新剧集",
|
||||||
|
"ToastNoRSSFeed": "播客没有 RSS 订阅",
|
||||||
"ToastNoUpdatesNecessary": "无需更新",
|
"ToastNoUpdatesNecessary": "无需更新",
|
||||||
"ToastNotificationCreateFailed": "无法创建通知",
|
"ToastNotificationCreateFailed": "无法创建通知",
|
||||||
"ToastNotificationDeleteFailed": "删除通知失败",
|
"ToastNotificationDeleteFailed": "删除通知失败",
|
||||||
|
@ -723,7 +723,6 @@
|
|||||||
"ToastBookmarkCreateFailed": "創建書簽失敗",
|
"ToastBookmarkCreateFailed": "創建書簽失敗",
|
||||||
"ToastBookmarkCreateSuccess": "書籤已新增",
|
"ToastBookmarkCreateSuccess": "書籤已新增",
|
||||||
"ToastBookmarkRemoveSuccess": "書籤已刪除",
|
"ToastBookmarkRemoveSuccess": "書籤已刪除",
|
||||||
"ToastBookmarkUpdateSuccess": "書籤已更新",
|
|
||||||
"ToastChaptersHaveErrors": "章節有錯誤",
|
"ToastChaptersHaveErrors": "章節有錯誤",
|
||||||
"ToastChaptersMustHaveTitles": "章節必須有標題",
|
"ToastChaptersMustHaveTitles": "章節必須有標題",
|
||||||
"ToastCollectionRemoveSuccess": "收藏夾已刪除",
|
"ToastCollectionRemoveSuccess": "收藏夾已刪除",
|
||||||
|
34
index.js
34
index.js
@ -1,3 +1,18 @@
|
|||||||
|
const optionDefinitions = [
|
||||||
|
{ name: 'config', alias: 'c', type: String },
|
||||||
|
{ name: 'metadata', alias: 'm', type: String },
|
||||||
|
{ name: 'port', alias: 'p', type: String },
|
||||||
|
{ name: 'host', alias: 'h', type: String },
|
||||||
|
{ name: 'source', alias: 's', type: String },
|
||||||
|
{ name: 'dev', alias: 'd', type: Boolean }
|
||||||
|
]
|
||||||
|
|
||||||
|
const commandLineArgs = require('./server/libs/commandLineArgs')
|
||||||
|
const options = commandLineArgs(optionDefinitions)
|
||||||
|
|
||||||
|
const Path = require('path')
|
||||||
|
process.env.NODE_ENV = options.dev ? 'development' : process.env.NODE_ENV || 'production'
|
||||||
|
|
||||||
const server = require('./server/Server')
|
const server = require('./server/Server')
|
||||||
global.appRoot = __dirname
|
global.appRoot = __dirname
|
||||||
|
|
||||||
@ -17,14 +32,19 @@ if (isDev) {
|
|||||||
process.env.ROUTER_BASE_PATH = devEnv.RouterBasePath || ''
|
process.env.ROUTER_BASE_PATH = devEnv.RouterBasePath || ''
|
||||||
}
|
}
|
||||||
|
|
||||||
const PORT = process.env.PORT || 80
|
const inputConfig = options.config ? Path.resolve(options.config) : null
|
||||||
const HOST = process.env.HOST
|
const inputMetadata = options.metadata ? Path.resolve(options.metadata) : null
|
||||||
const CONFIG_PATH = process.env.CONFIG_PATH || '/config'
|
|
||||||
const METADATA_PATH = process.env.METADATA_PATH || '/metadata'
|
|
||||||
const SOURCE = process.env.SOURCE || 'docker'
|
|
||||||
const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || ''
|
|
||||||
|
|
||||||
console.log('Config', CONFIG_PATH, METADATA_PATH)
|
const PORT = options.port || process.env.PORT || 3333
|
||||||
|
const HOST = options.host || process.env.HOST
|
||||||
|
const CONFIG_PATH = inputConfig || process.env.CONFIG_PATH || Path.resolve('config')
|
||||||
|
const METADATA_PATH = inputMetadata || process.env.METADATA_PATH || Path.resolve('metadata')
|
||||||
|
const SOURCE = options.source || process.env.SOURCE || 'debian'
|
||||||
|
|
||||||
|
const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || '/audiobookshelf'
|
||||||
|
|
||||||
|
console.log(`Running in ${process.env.NODE_ENV} mode.`)
|
||||||
|
console.log(`Options: CONFIG_PATH=${CONFIG_PATH}, METADATA_PATH=${METADATA_PATH}, PORT=${PORT}, HOST=${HOST}, SOURCE=${SOURCE}, ROUTER_BASE_PATH=${ROUTER_BASE_PATH}`)
|
||||||
|
|
||||||
const Server = new server(SOURCE, PORT, HOST, CONFIG_PATH, METADATA_PATH, ROUTER_BASE_PATH)
|
const Server = new server(SOURCE, PORT, HOST, CONFIG_PATH, METADATA_PATH, ROUTER_BASE_PATH)
|
||||||
Server.start()
|
Server.start()
|
||||||
|
6
package-lock.json
generated
6
package-lock.json
generated
@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "audiobookshelf",
|
"name": "audiobookshelf",
|
||||||
"version": "2.17.7",
|
"version": "2.18.0",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "audiobookshelf",
|
"name": "audiobookshelf",
|
||||||
"version": "2.17.7",
|
"version": "2.18.0",
|
||||||
"license": "GPL-3.0",
|
"license": "GPL-3.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"axios": "^0.27.2",
|
"axios": "^0.27.2",
|
||||||
@ -30,7 +30,7 @@
|
|||||||
"xml2js": "^0.5.0"
|
"xml2js": "^0.5.0"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
"audiobookshelf": "prod.js"
|
"audiobookshelf": "index.js"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"chai": "^4.3.10",
|
"chai": "^4.3.10",
|
||||||
|
10
package.json
10
package.json
@ -1,14 +1,14 @@
|
|||||||
{
|
{
|
||||||
"name": "audiobookshelf",
|
"name": "audiobookshelf",
|
||||||
"version": "2.17.7",
|
"version": "2.18.0",
|
||||||
"buildNumber": 1,
|
"buildNumber": 1,
|
||||||
"description": "Self-hosted audiobook and podcast server",
|
"description": "Self-hosted audiobook and podcast server",
|
||||||
"main": "index.js",
|
"main": "index.js",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"dev": "nodemon --watch server index.js",
|
"dev": "nodemon --watch server index.js -- --dev",
|
||||||
"start": "node index.js",
|
"start": "node index.js",
|
||||||
"client": "cd client && npm ci && npm run generate",
|
"client": "cd client && npm ci && npm run generate",
|
||||||
"prod": "npm run client && npm ci && node prod.js",
|
"prod": "npm run client && npm ci && node index.js",
|
||||||
"build-win": "npm run client && pkg -t node20-win-x64 -o ./dist/win/audiobookshelf -C GZip .",
|
"build-win": "npm run client && pkg -t node20-win-x64 -o ./dist/win/audiobookshelf -C GZip .",
|
||||||
"build-linux": "build/linuxpackager",
|
"build-linux": "build/linuxpackager",
|
||||||
"docker": "docker buildx build --platform linux/amd64,linux/arm64 --push . -t advplyr/audiobookshelf",
|
"docker": "docker buildx build --platform linux/amd64,linux/arm64 --push . -t advplyr/audiobookshelf",
|
||||||
@ -18,7 +18,7 @@
|
|||||||
"test": "mocha",
|
"test": "mocha",
|
||||||
"coverage": "nyc mocha"
|
"coverage": "nyc mocha"
|
||||||
},
|
},
|
||||||
"bin": "prod.js",
|
"bin": "index.js",
|
||||||
"pkg": {
|
"pkg": {
|
||||||
"assets": [
|
"assets": [
|
||||||
"client/dist/**/*",
|
"client/dist/**/*",
|
||||||
@ -26,7 +26,7 @@
|
|||||||
"server/migrations/*.js"
|
"server/migrations/*.js"
|
||||||
],
|
],
|
||||||
"scripts": [
|
"scripts": [
|
||||||
"prod.js",
|
"index.js",
|
||||||
"server/**/*.js"
|
"server/**/*.js"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
|
2
prod.js
2
prod.js
@ -25,7 +25,7 @@ const CONFIG_PATH = inputConfig || process.env.CONFIG_PATH || Path.resolve('conf
|
|||||||
const METADATA_PATH = inputMetadata || process.env.METADATA_PATH || Path.resolve('metadata')
|
const METADATA_PATH = inputMetadata || process.env.METADATA_PATH || Path.resolve('metadata')
|
||||||
const SOURCE = options.source || process.env.SOURCE || 'debian'
|
const SOURCE = options.source || process.env.SOURCE || 'debian'
|
||||||
|
|
||||||
const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || ''
|
const ROUTER_BASE_PATH = process.env.ROUTER_BASE_PATH || '/audiobookshelf'
|
||||||
|
|
||||||
console.log(process.env.NODE_ENV, 'Config', CONFIG_PATH, METADATA_PATH)
|
console.log(process.env.NODE_ENV, 'Config', CONFIG_PATH, METADATA_PATH)
|
||||||
|
|
||||||
|
@ -111,8 +111,8 @@ server {
|
|||||||
|
|
||||||
location / {
|
location / {
|
||||||
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
|
||||||
proxy_set_header X-Forwarded-Proto $scheme;
|
proxy_set_header X-Forwarded-Proto $scheme;
|
||||||
proxy_set_header Host $host;
|
proxy_set_header Host $http_host;
|
||||||
proxy_set_header Upgrade $http_upgrade;
|
proxy_set_header Upgrade $http_upgrade;
|
||||||
proxy_set_header Connection "upgrade";
|
proxy_set_header Connection "upgrade";
|
||||||
|
|
||||||
|
@ -401,45 +401,6 @@ class Database {
|
|||||||
return this.models.setting.updateSettingObj(settings.toJSON())
|
return this.models.setting.updateSettingObj(settings.toJSON())
|
||||||
}
|
}
|
||||||
|
|
||||||
updateBulkBooks(oldBooks) {
|
|
||||||
if (!this.sequelize) return false
|
|
||||||
return Promise.all(oldBooks.map((oldBook) => this.models.book.saveFromOld(oldBook)))
|
|
||||||
}
|
|
||||||
|
|
||||||
async createLibraryItem(oldLibraryItem) {
|
|
||||||
if (!this.sequelize) return false
|
|
||||||
await oldLibraryItem.saveMetadata()
|
|
||||||
await this.models.libraryItem.fullCreateFromOld(oldLibraryItem)
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Save metadata file and update library item
|
|
||||||
*
|
|
||||||
* @param {import('./objects/LibraryItem')} oldLibraryItem
|
|
||||||
* @returns {Promise<boolean>}
|
|
||||||
*/
|
|
||||||
async updateLibraryItem(oldLibraryItem) {
|
|
||||||
if (!this.sequelize) return false
|
|
||||||
await oldLibraryItem.saveMetadata()
|
|
||||||
const updated = await this.models.libraryItem.fullUpdateFromOld(oldLibraryItem)
|
|
||||||
// Clear library filter data cache
|
|
||||||
if (updated) {
|
|
||||||
delete this.libraryFilterData[oldLibraryItem.libraryId]
|
|
||||||
}
|
|
||||||
return updated
|
|
||||||
}
|
|
||||||
|
|
||||||
async createBulkBookAuthors(bookAuthors) {
|
|
||||||
if (!this.sequelize) return false
|
|
||||||
await this.models.bookAuthor.bulkCreate(bookAuthors)
|
|
||||||
}
|
|
||||||
|
|
||||||
async removeBulkBookAuthors(authorId = null, bookId = null) {
|
|
||||||
if (!this.sequelize) return false
|
|
||||||
if (!authorId && !bookId) return
|
|
||||||
await this.models.bookAuthor.removeByIds(authorId, bookId)
|
|
||||||
}
|
|
||||||
|
|
||||||
getPlaybackSessions(where = null) {
|
getPlaybackSessions(where = null) {
|
||||||
if (!this.sequelize) return false
|
if (!this.sequelize) return false
|
||||||
return this.models.playbackSession.getOldPlaybackSessions(where)
|
return this.models.playbackSession.getOldPlaybackSessions(where)
|
||||||
@ -665,7 +626,7 @@ class Database {
|
|||||||
/**
|
/**
|
||||||
* Clean invalid records in database
|
* Clean invalid records in database
|
||||||
* Series should have atleast one Book
|
* Series should have atleast one Book
|
||||||
* Book and Podcast must have an associated LibraryItem
|
* Book and Podcast must have an associated LibraryItem (and vice versa)
|
||||||
* Remove playback sessions that are 3 seconds or less
|
* Remove playback sessions that are 3 seconds or less
|
||||||
*/
|
*/
|
||||||
async cleanDatabase() {
|
async cleanDatabase() {
|
||||||
@ -695,6 +656,49 @@ class Database {
|
|||||||
await book.destroy()
|
await book.destroy()
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Remove invalid LibraryItem records
|
||||||
|
const libraryItemsWithNoMedia = await this.libraryItemModel.findAll({
|
||||||
|
include: [
|
||||||
|
{
|
||||||
|
model: this.bookModel,
|
||||||
|
attributes: ['id']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
model: this.podcastModel,
|
||||||
|
attributes: ['id']
|
||||||
|
}
|
||||||
|
],
|
||||||
|
where: {
|
||||||
|
'$book.id$': null,
|
||||||
|
'$podcast.id$': null
|
||||||
|
}
|
||||||
|
})
|
||||||
|
for (const libraryItem of libraryItemsWithNoMedia) {
|
||||||
|
Logger.warn(`Found libraryItem "${libraryItem.id}" with no media - removing it`)
|
||||||
|
await libraryItem.destroy()
|
||||||
|
}
|
||||||
|
|
||||||
|
const playlistMediaItemsWithNoMediaItem = await this.playlistMediaItemModel.findAll({
|
||||||
|
include: [
|
||||||
|
{
|
||||||
|
model: this.bookModel,
|
||||||
|
attributes: ['id']
|
||||||
|
},
|
||||||
|
{
|
||||||
|
model: this.podcastEpisodeModel,
|
||||||
|
attributes: ['id']
|
||||||
|
}
|
||||||
|
],
|
||||||
|
where: {
|
||||||
|
'$book.id$': null,
|
||||||
|
'$podcastEpisode.id$': null
|
||||||
|
}
|
||||||
|
})
|
||||||
|
for (const playlistMediaItem of playlistMediaItemsWithNoMediaItem) {
|
||||||
|
Logger.warn(`Found playlistMediaItem with no book or podcastEpisode - removing it`)
|
||||||
|
await playlistMediaItem.destroy()
|
||||||
|
}
|
||||||
|
|
||||||
// Remove empty series
|
// Remove empty series
|
||||||
const emptySeries = await this.seriesModel.findAll({
|
const emptySeries = await this.seriesModel.findAll({
|
||||||
include: {
|
include: {
|
||||||
|
@ -85,6 +85,12 @@ class Server {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (process.env.PODCAST_DOWNLOAD_TIMEOUT) {
|
||||||
|
global.PodcastDownloadTimeout = process.env.PODCAST_DOWNLOAD_TIMEOUT
|
||||||
|
} else {
|
||||||
|
global.PodcastDownloadTimeout = 30000
|
||||||
|
}
|
||||||
|
|
||||||
if (!fs.pathExistsSync(global.ConfigPath)) {
|
if (!fs.pathExistsSync(global.ConfigPath)) {
|
||||||
fs.mkdirSync(global.ConfigPath)
|
fs.mkdirSync(global.ConfigPath)
|
||||||
}
|
}
|
||||||
|
@ -44,16 +44,21 @@ class AuthorController {
|
|||||||
|
|
||||||
// Used on author landing page to include library items and items grouped in series
|
// Used on author landing page to include library items and items grouped in series
|
||||||
if (include.includes('items')) {
|
if (include.includes('items')) {
|
||||||
authorJson.libraryItems = await Database.libraryItemModel.getForAuthor(req.author, req.user)
|
const libraryItems = await Database.libraryItemModel.getForAuthor(req.author, req.user)
|
||||||
|
|
||||||
if (include.includes('series')) {
|
if (include.includes('series')) {
|
||||||
const seriesMap = {}
|
const seriesMap = {}
|
||||||
// Group items into series
|
// Group items into series
|
||||||
authorJson.libraryItems.forEach((li) => {
|
libraryItems.forEach((li) => {
|
||||||
if (li.media.metadata.series) {
|
if (li.media.series?.length) {
|
||||||
li.media.metadata.series.forEach((series) => {
|
li.media.series.forEach((series) => {
|
||||||
const itemWithSeries = li.toJSONMinified()
|
const itemWithSeries = li.toOldJSONMinified()
|
||||||
itemWithSeries.media.metadata.series = series
|
itemWithSeries.media.metadata.series = {
|
||||||
|
id: series.id,
|
||||||
|
name: series.name,
|
||||||
|
nameIgnorePrefix: series.nameIgnorePrefix,
|
||||||
|
sequence: series.bookSeries.sequence
|
||||||
|
}
|
||||||
|
|
||||||
if (seriesMap[series.id]) {
|
if (seriesMap[series.id]) {
|
||||||
seriesMap[series.id].items.push(itemWithSeries)
|
seriesMap[series.id].items.push(itemWithSeries)
|
||||||
@ -76,7 +81,7 @@ class AuthorController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Minify library items
|
// Minify library items
|
||||||
authorJson.libraryItems = authorJson.libraryItems.map((li) => li.toJSONMinified())
|
authorJson.libraryItems = libraryItems.map((li) => li.toOldJSONMinified())
|
||||||
}
|
}
|
||||||
|
|
||||||
return res.json(authorJson)
|
return res.json(authorJson)
|
||||||
@ -125,7 +130,7 @@ class AuthorController {
|
|||||||
const bookAuthorsToCreate = []
|
const bookAuthorsToCreate = []
|
||||||
const allItemsWithAuthor = await Database.authorModel.getAllLibraryItemsForAuthor(req.author.id)
|
const allItemsWithAuthor = await Database.authorModel.getAllLibraryItemsForAuthor(req.author.id)
|
||||||
|
|
||||||
const oldLibraryItems = []
|
const libraryItems = []
|
||||||
allItemsWithAuthor.forEach((libraryItem) => {
|
allItemsWithAuthor.forEach((libraryItem) => {
|
||||||
// Replace old author with merging author for each book
|
// Replace old author with merging author for each book
|
||||||
libraryItem.media.authors = libraryItem.media.authors.filter((au) => au.id !== req.author.id)
|
libraryItem.media.authors = libraryItem.media.authors.filter((au) => au.id !== req.author.id)
|
||||||
@ -134,23 +139,22 @@ class AuthorController {
|
|||||||
name: existingAuthor.name
|
name: existingAuthor.name
|
||||||
})
|
})
|
||||||
|
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
libraryItems.push(libraryItem)
|
||||||
oldLibraryItems.push(oldLibraryItem)
|
|
||||||
|
|
||||||
bookAuthorsToCreate.push({
|
bookAuthorsToCreate.push({
|
||||||
bookId: libraryItem.media.id,
|
bookId: libraryItem.media.id,
|
||||||
authorId: existingAuthor.id
|
authorId: existingAuthor.id
|
||||||
})
|
})
|
||||||
})
|
})
|
||||||
if (oldLibraryItems.length) {
|
if (libraryItems.length) {
|
||||||
await Database.removeBulkBookAuthors(req.author.id) // Remove all old BookAuthor
|
await Database.bookAuthorModel.removeByIds(req.author.id) // Remove all old BookAuthor
|
||||||
await Database.createBulkBookAuthors(bookAuthorsToCreate) // Create all new BookAuthor
|
await Database.bookAuthorModel.bulkCreate(bookAuthorsToCreate) // Create all new BookAuthor
|
||||||
for (const libraryItem of allItemsWithAuthor) {
|
for (const libraryItem of libraryItems) {
|
||||||
await libraryItem.saveMetadataFile()
|
await libraryItem.saveMetadataFile()
|
||||||
}
|
}
|
||||||
SocketAuthority.emitter(
|
SocketAuthority.emitter(
|
||||||
'items_updated',
|
'items_updated',
|
||||||
oldLibraryItems.map((li) => li.toJSONExpanded())
|
libraryItems.map((li) => li.toOldJSONExpanded())
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -190,7 +194,7 @@ class AuthorController {
|
|||||||
const allItemsWithAuthor = await Database.authorModel.getAllLibraryItemsForAuthor(req.author.id)
|
const allItemsWithAuthor = await Database.authorModel.getAllLibraryItemsForAuthor(req.author.id)
|
||||||
|
|
||||||
numBooksForAuthor = allItemsWithAuthor.length
|
numBooksForAuthor = allItemsWithAuthor.length
|
||||||
const oldLibraryItems = []
|
const libraryItems = []
|
||||||
// Update author name on all books
|
// Update author name on all books
|
||||||
for (const libraryItem of allItemsWithAuthor) {
|
for (const libraryItem of allItemsWithAuthor) {
|
||||||
libraryItem.media.authors = libraryItem.media.authors.map((au) => {
|
libraryItem.media.authors = libraryItem.media.authors.map((au) => {
|
||||||
@ -199,16 +203,16 @@ class AuthorController {
|
|||||||
}
|
}
|
||||||
return au
|
return au
|
||||||
})
|
})
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
oldLibraryItems.push(oldLibraryItem)
|
libraryItems.push(libraryItem)
|
||||||
|
|
||||||
await libraryItem.saveMetadataFile()
|
await libraryItem.saveMetadataFile()
|
||||||
}
|
}
|
||||||
|
|
||||||
if (oldLibraryItems.length) {
|
if (libraryItems.length) {
|
||||||
SocketAuthority.emitter(
|
SocketAuthority.emitter(
|
||||||
'items_updated',
|
'items_updated',
|
||||||
oldLibraryItems.map((li) => li.toJSONExpanded())
|
libraryItems.map((li) => li.toOldJSONExpanded())
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -238,8 +242,18 @@ class AuthorController {
|
|||||||
await CacheManager.purgeImageCache(req.author.id) // Purge cache
|
await CacheManager.purgeImageCache(req.author.id) // Purge cache
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Load library items so that metadata file can be updated
|
||||||
|
const allItemsWithAuthor = await Database.authorModel.getAllLibraryItemsForAuthor(req.author.id)
|
||||||
|
allItemsWithAuthor.forEach((libraryItem) => {
|
||||||
|
libraryItem.media.authors = libraryItem.media.authors.filter((au) => au.id !== req.author.id)
|
||||||
|
})
|
||||||
|
|
||||||
await req.author.destroy()
|
await req.author.destroy()
|
||||||
|
|
||||||
|
for (const libraryItem of allItemsWithAuthor) {
|
||||||
|
await libraryItem.saveMetadataFile()
|
||||||
|
}
|
||||||
|
|
||||||
SocketAuthority.emitter('author_removed', req.author.toOldJSON())
|
SocketAuthority.emitter('author_removed', req.author.toOldJSON())
|
||||||
|
|
||||||
// Update filter data
|
// Update filter data
|
||||||
|
@ -221,7 +221,9 @@ class CollectionController {
|
|||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async addBook(req, res) {
|
async addBook(req, res) {
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(req.body.id)
|
const libraryItem = await Database.libraryItemModel.findByPk(req.body.id, {
|
||||||
|
attributes: ['libraryId', 'mediaId']
|
||||||
|
})
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
return res.status(404).send('Book not found')
|
return res.status(404).send('Book not found')
|
||||||
}
|
}
|
||||||
@ -231,14 +233,14 @@ class CollectionController {
|
|||||||
|
|
||||||
// Check if book is already in collection
|
// Check if book is already in collection
|
||||||
const collectionBooks = await req.collection.getCollectionBooks()
|
const collectionBooks = await req.collection.getCollectionBooks()
|
||||||
if (collectionBooks.some((cb) => cb.bookId === libraryItem.media.id)) {
|
if (collectionBooks.some((cb) => cb.bookId === libraryItem.mediaId)) {
|
||||||
return res.status(400).send('Book already in collection')
|
return res.status(400).send('Book already in collection')
|
||||||
}
|
}
|
||||||
|
|
||||||
// Create collectionBook record
|
// Create collectionBook record
|
||||||
await Database.collectionBookModel.create({
|
await Database.collectionBookModel.create({
|
||||||
collectionId: req.collection.id,
|
collectionId: req.collection.id,
|
||||||
bookId: libraryItem.media.id,
|
bookId: libraryItem.mediaId,
|
||||||
order: collectionBooks.length + 1
|
order: collectionBooks.length + 1
|
||||||
})
|
})
|
||||||
const jsonExpanded = await req.collection.getOldJsonExpanded()
|
const jsonExpanded = await req.collection.getOldJsonExpanded()
|
||||||
@ -255,7 +257,9 @@ class CollectionController {
|
|||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async removeBook(req, res) {
|
async removeBook(req, res) {
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(req.params.bookId)
|
const libraryItem = await Database.libraryItemModel.findByPk(req.params.bookId, {
|
||||||
|
attributes: ['mediaId']
|
||||||
|
})
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
@ -266,7 +270,7 @@ class CollectionController {
|
|||||||
})
|
})
|
||||||
|
|
||||||
let jsonExpanded = null
|
let jsonExpanded = null
|
||||||
const collectionBookToRemove = collectionBooks.find((cb) => cb.bookId === libraryItem.media.id)
|
const collectionBookToRemove = collectionBooks.find((cb) => cb.bookId === libraryItem.mediaId)
|
||||||
if (collectionBookToRemove) {
|
if (collectionBookToRemove) {
|
||||||
// Remove collection book record
|
// Remove collection book record
|
||||||
await collectionBookToRemove.destroy()
|
await collectionBookToRemove.destroy()
|
||||||
@ -274,7 +278,7 @@ class CollectionController {
|
|||||||
// Update order on collection books
|
// Update order on collection books
|
||||||
let order = 1
|
let order = 1
|
||||||
for (const collectionBook of collectionBooks) {
|
for (const collectionBook of collectionBooks) {
|
||||||
if (collectionBook.bookId === libraryItem.media.id) continue
|
if (collectionBook.bookId === libraryItem.mediaId) continue
|
||||||
if (collectionBook.order !== order) {
|
if (collectionBook.order !== order) {
|
||||||
await collectionBook.update({
|
await collectionBook.update({
|
||||||
order
|
order
|
||||||
|
@ -106,7 +106,7 @@ class EmailController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(req.body.libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(req.body.libraryItemId)
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
return res.status(404).send('Library item not found')
|
return res.status(404).send('Library item not found')
|
||||||
}
|
}
|
||||||
|
@ -100,6 +100,15 @@ class LibraryController {
|
|||||||
return res.status(400).send(`Invalid request. Settings "${key}" must be a string`)
|
return res.status(400).send(`Invalid request. Settings "${key}" must be a string`)
|
||||||
}
|
}
|
||||||
newLibraryPayload.settings[key] = req.body.settings[key]
|
newLibraryPayload.settings[key] = req.body.settings[key]
|
||||||
|
} else if (key === 'markAsFinishedPercentComplete' || key === 'markAsFinishedTimeRemaining') {
|
||||||
|
if (req.body.settings[key] !== null && isNaN(req.body.settings[key])) {
|
||||||
|
return res.status(400).send(`Invalid request. Setting "${key}" must be a number`)
|
||||||
|
} else if (key === 'markAsFinishedPercentComplete' && req.body.settings[key] !== null && (Number(req.body.settings[key]) < 0 || Number(req.body.settings[key]) > 100)) {
|
||||||
|
return res.status(400).send(`Invalid request. Setting "${key}" must be between 0 and 100`)
|
||||||
|
} else if (key === 'markAsFinishedTimeRemaining' && req.body.settings[key] !== null && Number(req.body.settings[key]) < 0) {
|
||||||
|
return res.status(400).send(`Invalid request. Setting "${key}" must be greater than or equal to 0`)
|
||||||
|
}
|
||||||
|
newLibraryPayload.settings[key] = req.body.settings[key] === null ? null : Number(req.body.settings[key])
|
||||||
} else {
|
} else {
|
||||||
if (typeof req.body.settings[key] !== typeof newLibraryPayload.settings[key]) {
|
if (typeof req.body.settings[key] !== typeof newLibraryPayload.settings[key]) {
|
||||||
return res.status(400).send(`Invalid request. Setting "${key}" must be of type ${typeof newLibraryPayload.settings[key]}`)
|
return res.status(400).send(`Invalid request. Setting "${key}" must be of type ${typeof newLibraryPayload.settings[key]}`)
|
||||||
@ -170,21 +179,34 @@ class LibraryController {
|
|||||||
* GET: /api/libraries
|
* GET: /api/libraries
|
||||||
* Get all libraries
|
* Get all libraries
|
||||||
*
|
*
|
||||||
|
* ?include=stats to load library stats - used in android auto to filter out libraries with no audio
|
||||||
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithUser} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async findAll(req, res) {
|
async findAll(req, res) {
|
||||||
const libraries = await Database.libraryModel.getAllWithFolders()
|
let libraries = await Database.libraryModel.getAllWithFolders()
|
||||||
|
|
||||||
const librariesAccessible = req.user.permissions?.librariesAccessible || []
|
const librariesAccessible = req.user.permissions?.librariesAccessible || []
|
||||||
if (librariesAccessible.length) {
|
if (librariesAccessible.length) {
|
||||||
return res.json({
|
libraries = libraries.filter((lib) => librariesAccessible.includes(lib.id))
|
||||||
libraries: libraries.filter((lib) => librariesAccessible.includes(lib.id)).map((lib) => lib.toOldJSON())
|
}
|
||||||
})
|
|
||||||
|
libraries = libraries.map((lib) => lib.toOldJSON())
|
||||||
|
|
||||||
|
const includeArray = (req.query.include || '').split(',')
|
||||||
|
if (includeArray.includes('stats')) {
|
||||||
|
for (const library of libraries) {
|
||||||
|
if (library.mediaType === 'book') {
|
||||||
|
library.stats = await libraryItemsBookFilters.getBookLibraryStats(library.id)
|
||||||
|
} else if (library.mediaType === 'podcast') {
|
||||||
|
library.stats = await libraryItemsPodcastFilters.getPodcastLibraryStats(library.id)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
res.json({
|
res.json({
|
||||||
libraries: libraries.map((lib) => lib.toOldJSON())
|
libraries
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -312,7 +334,7 @@ class LibraryController {
|
|||||||
}
|
}
|
||||||
if (req.body.settings[key] !== updatedSettings[key]) {
|
if (req.body.settings[key] !== updatedSettings[key]) {
|
||||||
hasUpdates = true
|
hasUpdates = true
|
||||||
updatedSettings[key] = Number(req.body.settings[key])
|
updatedSettings[key] = req.body.settings[key] === null ? null : Number(req.body.settings[key])
|
||||||
Logger.debug(`[LibraryController] Library "${req.library.name}" updating setting "${key}" to "${updatedSettings[key]}"`)
|
Logger.debug(`[LibraryController] Library "${req.library.name}" updating setting "${key}" to "${updatedSettings[key]}"`)
|
||||||
}
|
}
|
||||||
} else if (key === 'markAsFinishedTimeRemaining') {
|
} else if (key === 'markAsFinishedTimeRemaining') {
|
||||||
@ -325,7 +347,7 @@ class LibraryController {
|
|||||||
}
|
}
|
||||||
if (req.body.settings[key] !== updatedSettings[key]) {
|
if (req.body.settings[key] !== updatedSettings[key]) {
|
||||||
hasUpdates = true
|
hasUpdates = true
|
||||||
updatedSettings[key] = Number(req.body.settings[key])
|
updatedSettings[key] = req.body.settings[key] === null ? null : Number(req.body.settings[key])
|
||||||
Logger.debug(`[LibraryController] Library "${req.library.name}" updating setting "${key}" to "${updatedSettings[key]}"`)
|
Logger.debug(`[LibraryController] Library "${req.library.name}" updating setting "${key}" to "${updatedSettings[key]}"`)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
@ -1145,14 +1167,14 @@ class LibraryController {
|
|||||||
await libraryItem.media.update({
|
await libraryItem.media.update({
|
||||||
narrators: libraryItem.media.narrators
|
narrators: libraryItem.media.narrators
|
||||||
})
|
})
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
itemsUpdated.push(oldLibraryItem)
|
itemsUpdated.push(libraryItem)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (itemsUpdated.length) {
|
if (itemsUpdated.length) {
|
||||||
SocketAuthority.emitter(
|
SocketAuthority.emitter(
|
||||||
'items_updated',
|
'items_updated',
|
||||||
itemsUpdated.map((li) => li.toJSONExpanded())
|
itemsUpdated.map((li) => li.toOldJSONExpanded())
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1189,14 +1211,14 @@ class LibraryController {
|
|||||||
await libraryItem.media.update({
|
await libraryItem.media.update({
|
||||||
narrators: libraryItem.media.narrators
|
narrators: libraryItem.media.narrators
|
||||||
})
|
})
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
itemsUpdated.push(oldLibraryItem)
|
itemsUpdated.push(libraryItem)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (itemsUpdated.length) {
|
if (itemsUpdated.length) {
|
||||||
SocketAuthority.emitter(
|
SocketAuthority.emitter(
|
||||||
'items_updated',
|
'items_updated',
|
||||||
itemsUpdated.map((li) => li.toJSONExpanded())
|
itemsUpdated.map((li) => li.toOldJSONExpanded())
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -24,6 +24,16 @@ const ShareManager = require('../managers/ShareManager')
|
|||||||
* @property {import('../models/User')} user
|
* @property {import('../models/User')} user
|
||||||
*
|
*
|
||||||
* @typedef {Request & RequestUserObject} RequestWithUser
|
* @typedef {Request & RequestUserObject} RequestWithUser
|
||||||
|
*
|
||||||
|
* @typedef RequestEntityObject
|
||||||
|
* @property {import('../models/LibraryItem')} libraryItem
|
||||||
|
*
|
||||||
|
* @typedef {RequestWithUser & RequestEntityObject} LibraryItemControllerRequest
|
||||||
|
*
|
||||||
|
* @typedef RequestLibraryFileObject
|
||||||
|
* @property {import('../objects/files/LibraryFile')} libraryFile
|
||||||
|
*
|
||||||
|
* @typedef {RequestWithUser & RequestEntityObject & RequestLibraryFileObject} LibraryItemControllerRequestWithFile
|
||||||
*/
|
*/
|
||||||
|
|
||||||
class LibraryItemController {
|
class LibraryItemController {
|
||||||
@ -35,17 +45,17 @@ class LibraryItemController {
|
|||||||
* ?include=progress,rssfeed,downloads,share
|
* ?include=progress,rssfeed,downloads,share
|
||||||
* ?expanded=1
|
* ?expanded=1
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async findOne(req, res) {
|
async findOne(req, res) {
|
||||||
const includeEntities = (req.query.include || '').split(',')
|
const includeEntities = (req.query.include || '').split(',')
|
||||||
if (req.query.expanded == 1) {
|
if (req.query.expanded == 1) {
|
||||||
var item = req.libraryItem.toJSONExpanded()
|
const item = req.libraryItem.toOldJSONExpanded()
|
||||||
|
|
||||||
// Include users media progress
|
// Include users media progress
|
||||||
if (includeEntities.includes('progress')) {
|
if (includeEntities.includes('progress')) {
|
||||||
var episodeId = req.query.episode || null
|
const episodeId = req.query.episode || null
|
||||||
item.userMediaProgress = req.user.getOldMediaProgress(item.id, episodeId)
|
item.userMediaProgress = req.user.getOldMediaProgress(item.id, episodeId)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -68,28 +78,7 @@ class LibraryItemController {
|
|||||||
|
|
||||||
return res.json(item)
|
return res.json(item)
|
||||||
}
|
}
|
||||||
res.json(req.libraryItem)
|
res.json(req.libraryItem.toOldJSON())
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
* @param {RequestWithUser} req
|
|
||||||
* @param {Response} res
|
|
||||||
*/
|
|
||||||
async update(req, res) {
|
|
||||||
var libraryItem = req.libraryItem
|
|
||||||
// Item has cover and update is removing cover so purge it from cache
|
|
||||||
if (libraryItem.media.coverPath && req.body.media && (req.body.media.coverPath === '' || req.body.media.coverPath === null)) {
|
|
||||||
await CacheManager.purgeCoverCache(libraryItem.id)
|
|
||||||
}
|
|
||||||
|
|
||||||
const hasUpdates = libraryItem.update(req.body)
|
|
||||||
if (hasUpdates) {
|
|
||||||
Logger.debug(`[LibraryItemController] Updated now saving`)
|
|
||||||
await Database.updateLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
|
||||||
}
|
|
||||||
res.json(libraryItem.toJSON())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -100,7 +89,7 @@ class LibraryItemController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async delete(req, res) {
|
async delete(req, res) {
|
||||||
@ -111,14 +100,14 @@ class LibraryItemController {
|
|||||||
const authorIds = []
|
const authorIds = []
|
||||||
const seriesIds = []
|
const seriesIds = []
|
||||||
if (req.libraryItem.isPodcast) {
|
if (req.libraryItem.isPodcast) {
|
||||||
mediaItemIds.push(...req.libraryItem.media.episodes.map((ep) => ep.id))
|
mediaItemIds.push(...req.libraryItem.media.podcastEpisodes.map((ep) => ep.id))
|
||||||
} else {
|
} else {
|
||||||
mediaItemIds.push(req.libraryItem.media.id)
|
mediaItemIds.push(req.libraryItem.media.id)
|
||||||
if (req.libraryItem.media.metadata.authors?.length) {
|
if (req.libraryItem.media.authors?.length) {
|
||||||
authorIds.push(...req.libraryItem.media.metadata.authors.map((au) => au.id))
|
authorIds.push(...req.libraryItem.media.authors.map((au) => au.id))
|
||||||
}
|
}
|
||||||
if (req.libraryItem.media.metadata.series?.length) {
|
if (req.libraryItem.media.series?.length) {
|
||||||
seriesIds.push(...req.libraryItem.media.metadata.series.map((se) => se.id))
|
seriesIds.push(...req.libraryItem.media.series.map((se) => se.id))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -155,7 +144,7 @@ class LibraryItemController {
|
|||||||
* GET: /api/items/:id/download
|
* GET: /api/items/:id/download
|
||||||
* Download library item. Zip file if multiple files.
|
* Download library item. Zip file if multiple files.
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async download(req, res) {
|
async download(req, res) {
|
||||||
@ -164,7 +153,7 @@ class LibraryItemController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
const libraryItemPath = req.libraryItem.path
|
const libraryItemPath = req.libraryItem.path
|
||||||
const itemTitle = req.libraryItem.media.metadata.title
|
const itemTitle = req.libraryItem.media.title
|
||||||
|
|
||||||
Logger.info(`[LibraryItemController] User "${req.user.username}" requested download for item "${itemTitle}" at "${libraryItemPath}"`)
|
Logger.info(`[LibraryItemController] User "${req.user.username}" requested download for item "${itemTitle}" at "${libraryItemPath}"`)
|
||||||
|
|
||||||
@ -194,11 +183,10 @@ class LibraryItemController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async updateMedia(req, res) {
|
async updateMedia(req, res) {
|
||||||
const libraryItem = req.libraryItem
|
|
||||||
const mediaPayload = req.body
|
const mediaPayload = req.body
|
||||||
|
|
||||||
if (mediaPayload.url) {
|
if (mediaPayload.url) {
|
||||||
@ -206,69 +194,79 @@ class LibraryItemController {
|
|||||||
if (res.writableEnded || res.headersSent) return
|
if (res.writableEnded || res.headersSent) return
|
||||||
}
|
}
|
||||||
|
|
||||||
// Book specific
|
|
||||||
if (libraryItem.isBook) {
|
|
||||||
await this.createAuthorsAndSeriesForItemUpdate(mediaPayload, libraryItem.libraryId)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Podcast specific
|
// Podcast specific
|
||||||
let isPodcastAutoDownloadUpdated = false
|
let isPodcastAutoDownloadUpdated = false
|
||||||
if (libraryItem.isPodcast) {
|
if (req.libraryItem.isPodcast) {
|
||||||
if (mediaPayload.autoDownloadEpisodes !== undefined && libraryItem.media.autoDownloadEpisodes !== mediaPayload.autoDownloadEpisodes) {
|
if (mediaPayload.autoDownloadEpisodes !== undefined && req.libraryItem.media.autoDownloadEpisodes !== mediaPayload.autoDownloadEpisodes) {
|
||||||
isPodcastAutoDownloadUpdated = true
|
isPodcastAutoDownloadUpdated = true
|
||||||
} else if (mediaPayload.autoDownloadSchedule !== undefined && libraryItem.media.autoDownloadSchedule !== mediaPayload.autoDownloadSchedule) {
|
} else if (mediaPayload.autoDownloadSchedule !== undefined && req.libraryItem.media.autoDownloadSchedule !== mediaPayload.autoDownloadSchedule) {
|
||||||
isPodcastAutoDownloadUpdated = true
|
isPodcastAutoDownloadUpdated = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// Book specific - Get all series being removed from this item
|
let hasUpdates = (await req.libraryItem.media.updateFromRequest(mediaPayload)) || mediaPayload.url
|
||||||
let seriesRemoved = []
|
|
||||||
if (libraryItem.isBook && mediaPayload.metadata?.series) {
|
|
||||||
const seriesIdsInUpdate = mediaPayload.metadata.series?.map((se) => se.id) || []
|
|
||||||
seriesRemoved = libraryItem.media.metadata.series.filter((se) => !seriesIdsInUpdate.includes(se.id))
|
|
||||||
}
|
|
||||||
|
|
||||||
let authorsRemoved = []
|
if (req.libraryItem.isBook && Array.isArray(mediaPayload.metadata?.series)) {
|
||||||
if (libraryItem.isBook && mediaPayload.metadata?.authors) {
|
const seriesUpdateData = await req.libraryItem.media.updateSeriesFromRequest(mediaPayload.metadata.series, req.libraryItem.libraryId)
|
||||||
const authorIdsInUpdate = mediaPayload.metadata.authors.map((au) => au.id)
|
if (seriesUpdateData?.seriesRemoved.length) {
|
||||||
authorsRemoved = libraryItem.media.metadata.authors.filter((au) => !authorIdsInUpdate.includes(au.id))
|
|
||||||
}
|
|
||||||
|
|
||||||
const hasUpdates = libraryItem.media.update(mediaPayload) || mediaPayload.url
|
|
||||||
if (hasUpdates) {
|
|
||||||
libraryItem.updatedAt = Date.now()
|
|
||||||
|
|
||||||
if (isPodcastAutoDownloadUpdated) {
|
|
||||||
this.cronManager.checkUpdatePodcastCron(libraryItem)
|
|
||||||
}
|
|
||||||
|
|
||||||
Logger.debug(`[LibraryItemController] Updated library item media ${libraryItem.media.metadata.title}`)
|
|
||||||
await Database.updateLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
|
||||||
|
|
||||||
if (authorsRemoved.length) {
|
|
||||||
// Check remove empty authors
|
|
||||||
Logger.debug(`[LibraryItemController] Authors were removed from book. Check if authors are now empty.`)
|
|
||||||
await this.checkRemoveAuthorsWithNoBooks(authorsRemoved.map((au) => au.id))
|
|
||||||
}
|
|
||||||
if (seriesRemoved.length) {
|
|
||||||
// Check remove empty series
|
// Check remove empty series
|
||||||
Logger.debug(`[LibraryItemController] Series were removed from book. Check if series are now empty.`)
|
Logger.debug(`[LibraryItemController] Series were removed from book. Check if series are now empty.`)
|
||||||
await this.checkRemoveEmptySeries(seriesRemoved.map((se) => se.id))
|
await this.checkRemoveEmptySeries(seriesUpdateData.seriesRemoved.map((se) => se.id))
|
||||||
}
|
}
|
||||||
|
if (seriesUpdateData?.seriesAdded.length) {
|
||||||
|
// Add series to filter data
|
||||||
|
seriesUpdateData.seriesAdded.forEach((se) => {
|
||||||
|
Database.addSeriesToFilterData(req.libraryItem.libraryId, se.name, se.id)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
if (seriesUpdateData?.hasUpdates) {
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (req.libraryItem.isBook && Array.isArray(mediaPayload.metadata?.authors)) {
|
||||||
|
const authorNames = mediaPayload.metadata.authors.map((au) => (typeof au.name === 'string' ? au.name.trim() : null)).filter((au) => au)
|
||||||
|
const authorUpdateData = await req.libraryItem.media.updateAuthorsFromRequest(authorNames, req.libraryItem.libraryId)
|
||||||
|
if (authorUpdateData?.authorsRemoved.length) {
|
||||||
|
// Check remove empty authors
|
||||||
|
Logger.debug(`[LibraryItemController] Authors were removed from book. Check if authors are now empty.`)
|
||||||
|
await this.checkRemoveAuthorsWithNoBooks(authorUpdateData.authorsRemoved.map((au) => au.id))
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
if (authorUpdateData?.authorsAdded.length) {
|
||||||
|
// Add authors to filter data
|
||||||
|
authorUpdateData.authorsAdded.forEach((au) => {
|
||||||
|
Database.addAuthorToFilterData(req.libraryItem.libraryId, au.name, au.id)
|
||||||
|
})
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hasUpdates) {
|
||||||
|
req.libraryItem.changed('updatedAt', true)
|
||||||
|
await req.libraryItem.save()
|
||||||
|
|
||||||
|
await req.libraryItem.saveMetadataFile()
|
||||||
|
|
||||||
|
if (isPodcastAutoDownloadUpdated) {
|
||||||
|
this.cronManager.checkUpdatePodcastCron(req.libraryItem)
|
||||||
|
}
|
||||||
|
|
||||||
|
Logger.debug(`[LibraryItemController] Updated library item media ${req.libraryItem.media.title}`)
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
}
|
}
|
||||||
res.json({
|
res.json({
|
||||||
updated: hasUpdates,
|
updated: hasUpdates,
|
||||||
libraryItem
|
libraryItem: req.libraryItem.toOldJSON()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* POST: /api/items/:id/cover
|
* POST: /api/items/:id/cover
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
* @param {boolean} [updateAndReturnJson=true]
|
* @param {boolean} [updateAndReturnJson=true] - Allows the function to be used for both direct API calls and internally
|
||||||
*/
|
*/
|
||||||
async uploadCover(req, res, updateAndReturnJson = true) {
|
async uploadCover(req, res, updateAndReturnJson = true) {
|
||||||
if (!req.user.canUpload) {
|
if (!req.user.canUpload) {
|
||||||
@ -276,15 +274,13 @@ class LibraryItemController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
let libraryItem = req.libraryItem
|
|
||||||
|
|
||||||
let result = null
|
let result = null
|
||||||
if (req.body?.url) {
|
if (req.body?.url) {
|
||||||
Logger.debug(`[LibraryItemController] Requesting download cover from url "${req.body.url}"`)
|
Logger.debug(`[LibraryItemController] Requesting download cover from url "${req.body.url}"`)
|
||||||
result = await CoverManager.downloadCoverFromUrl(libraryItem, req.body.url)
|
result = await CoverManager.downloadCoverFromUrlNew(req.body.url, req.libraryItem.id, req.libraryItem.isFile ? null : req.libraryItem.path)
|
||||||
} else if (req.files?.cover) {
|
} else if (req.files?.cover) {
|
||||||
Logger.debug(`[LibraryItemController] Handling uploaded cover`)
|
Logger.debug(`[LibraryItemController] Handling uploaded cover`)
|
||||||
result = await CoverManager.uploadCover(libraryItem, req.files.cover)
|
result = await CoverManager.uploadCover(req.libraryItem, req.files.cover)
|
||||||
} else {
|
} else {
|
||||||
return res.status(400).send('Invalid request no file or url')
|
return res.status(400).send('Invalid request no file or url')
|
||||||
}
|
}
|
||||||
@ -295,9 +291,16 @@ class LibraryItemController {
|
|||||||
return res.status(500).send('Unknown error occurred')
|
return res.status(500).send('Unknown error occurred')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
req.libraryItem.media.coverPath = result.cover
|
||||||
|
req.libraryItem.media.changed('coverPath', true)
|
||||||
|
await req.libraryItem.media.save()
|
||||||
|
|
||||||
if (updateAndReturnJson) {
|
if (updateAndReturnJson) {
|
||||||
await Database.updateLibraryItem(libraryItem)
|
// client uses updatedAt timestamp in URL to force refresh cover
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
req.libraryItem.changed('updatedAt', true)
|
||||||
|
await req.libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
res.json({
|
res.json({
|
||||||
success: true,
|
success: true,
|
||||||
cover: result.cover
|
cover: result.cover
|
||||||
@ -308,22 +311,28 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* PATCH: /api/items/:id/cover
|
* PATCH: /api/items/:id/cover
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async updateCover(req, res) {
|
async updateCover(req, res) {
|
||||||
const libraryItem = req.libraryItem
|
|
||||||
if (!req.body.cover) {
|
if (!req.body.cover) {
|
||||||
return res.status(400).send('Invalid request no cover path')
|
return res.status(400).send('Invalid request no cover path')
|
||||||
}
|
}
|
||||||
|
|
||||||
const validationResult = await CoverManager.validateCoverPath(req.body.cover, libraryItem)
|
const validationResult = await CoverManager.validateCoverPath(req.body.cover, req.libraryItem)
|
||||||
if (validationResult.error) {
|
if (validationResult.error) {
|
||||||
return res.status(500).send(validationResult.error)
|
return res.status(500).send(validationResult.error)
|
||||||
}
|
}
|
||||||
if (validationResult.updated) {
|
if (validationResult.updated) {
|
||||||
await Database.updateLibraryItem(libraryItem)
|
req.libraryItem.media.coverPath = validationResult.cover
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
req.libraryItem.media.changed('coverPath', true)
|
||||||
|
await req.libraryItem.media.save()
|
||||||
|
|
||||||
|
// client uses updatedAt timestamp in URL to force refresh cover
|
||||||
|
req.libraryItem.changed('updatedAt', true)
|
||||||
|
await req.libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
}
|
}
|
||||||
res.json({
|
res.json({
|
||||||
success: true,
|
success: true,
|
||||||
@ -334,17 +343,22 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* DELETE: /api/items/:id/cover
|
* DELETE: /api/items/:id/cover
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async removeCover(req, res) {
|
async removeCover(req, res) {
|
||||||
var libraryItem = req.libraryItem
|
if (req.libraryItem.media.coverPath) {
|
||||||
|
req.libraryItem.media.coverPath = null
|
||||||
|
req.libraryItem.media.changed('coverPath', true)
|
||||||
|
await req.libraryItem.media.save()
|
||||||
|
|
||||||
if (libraryItem.media.coverPath) {
|
// client uses updatedAt timestamp in URL to force refresh cover
|
||||||
libraryItem.updateMediaCover('')
|
req.libraryItem.changed('updatedAt', true)
|
||||||
await CacheManager.purgeCoverCache(libraryItem.id)
|
await req.libraryItem.save()
|
||||||
await Database.updateLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
await CacheManager.purgeCoverCache(req.libraryItem.id)
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
}
|
}
|
||||||
|
|
||||||
res.sendStatus(200)
|
res.sendStatus(200)
|
||||||
@ -353,7 +367,7 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* GET: /api/items/:id/cover
|
* GET: /api/items/:id/cover
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async getCover(req, res) {
|
async getCover(req, res) {
|
||||||
@ -395,11 +409,11 @@ class LibraryItemController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
startPlaybackSession(req, res) {
|
startPlaybackSession(req, res) {
|
||||||
if (!req.libraryItem.media.numTracks) {
|
if (!req.libraryItem.hasAudioTracks) {
|
||||||
Logger.error(`[LibraryItemController] startPlaybackSession cannot playback ${req.libraryItem.id}`)
|
Logger.error(`[LibraryItemController] startPlaybackSession cannot playback ${req.libraryItem.id}`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
@ -412,18 +426,18 @@ class LibraryItemController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
startEpisodePlaybackSession(req, res) {
|
startEpisodePlaybackSession(req, res) {
|
||||||
var libraryItem = req.libraryItem
|
if (!req.libraryItem.isPodcast) {
|
||||||
if (!libraryItem.media.numTracks) {
|
Logger.error(`[LibraryItemController] startEpisodePlaybackSession invalid media type ${req.libraryItem.id}`)
|
||||||
Logger.error(`[LibraryItemController] startPlaybackSession cannot playback ${libraryItem.id}`)
|
return res.sendStatus(400)
|
||||||
return res.sendStatus(404)
|
|
||||||
}
|
}
|
||||||
var episodeId = req.params.episodeId
|
|
||||||
if (!libraryItem.media.episodes.find((ep) => ep.id === episodeId)) {
|
const episodeId = req.params.episodeId
|
||||||
Logger.error(`[LibraryItemController] startPlaybackSession episode ${episodeId} not found for item ${libraryItem.id}`)
|
if (!req.libraryItem.media.podcastEpisodes.some((ep) => ep.id === episodeId)) {
|
||||||
|
Logger.error(`[LibraryItemController] startPlaybackSession episode ${episodeId} not found for item ${req.libraryItem.id}`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -433,30 +447,55 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* PATCH: /api/items/:id/tracks
|
* PATCH: /api/items/:id/tracks
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async updateTracks(req, res) {
|
async updateTracks(req, res) {
|
||||||
var libraryItem = req.libraryItem
|
const orderedFileData = req.body?.orderedFileData
|
||||||
var orderedFileData = req.body.orderedFileData
|
|
||||||
if (!libraryItem.media.updateAudioTracks) {
|
if (!req.libraryItem.isBook) {
|
||||||
Logger.error(`[LibraryItemController] updateTracks invalid media type ${libraryItem.id}`)
|
Logger.error(`[LibraryItemController] updateTracks invalid media type ${req.libraryItem.id}`)
|
||||||
return res.sendStatus(500)
|
return res.sendStatus(400)
|
||||||
}
|
}
|
||||||
libraryItem.media.updateAudioTracks(orderedFileData)
|
if (!Array.isArray(orderedFileData) || !orderedFileData.length) {
|
||||||
await Database.updateLibraryItem(libraryItem)
|
Logger.error(`[LibraryItemController] updateTracks invalid orderedFileData ${req.libraryItem.id}`)
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
return res.sendStatus(400)
|
||||||
res.json(libraryItem.toJSON())
|
}
|
||||||
|
// Ensure that each orderedFileData has a valid ino and is in the book audioFiles
|
||||||
|
if (orderedFileData.some((fileData) => !fileData?.ino || !req.libraryItem.media.audioFiles.some((af) => af.ino === fileData.ino))) {
|
||||||
|
Logger.error(`[LibraryItemController] updateTracks invalid orderedFileData ${req.libraryItem.id}`)
|
||||||
|
return res.sendStatus(400)
|
||||||
|
}
|
||||||
|
|
||||||
|
let index = 1
|
||||||
|
const updatedAudioFiles = orderedFileData.map((fileData) => {
|
||||||
|
const audioFile = req.libraryItem.media.audioFiles.find((af) => af.ino === fileData.ino)
|
||||||
|
audioFile.manuallyVerified = true
|
||||||
|
audioFile.exclude = !!fileData.exclude
|
||||||
|
if (audioFile.exclude) {
|
||||||
|
audioFile.index = -1
|
||||||
|
} else {
|
||||||
|
audioFile.index = index++
|
||||||
|
}
|
||||||
|
return audioFile
|
||||||
|
})
|
||||||
|
updatedAudioFiles.sort((a, b) => a.index - b.index)
|
||||||
|
|
||||||
|
req.libraryItem.media.audioFiles = updatedAudioFiles
|
||||||
|
req.libraryItem.media.changed('audioFiles', true)
|
||||||
|
await req.libraryItem.media.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
|
res.json(req.libraryItem.toOldJSON())
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* POST /api/items/:id/match
|
* POST /api/items/:id/match
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async match(req, res) {
|
async match(req, res) {
|
||||||
const libraryItem = req.libraryItem
|
|
||||||
const reqBody = req.body || {}
|
const reqBody = req.body || {}
|
||||||
|
|
||||||
const options = {}
|
const options = {}
|
||||||
@ -473,7 +512,7 @@ class LibraryItemController {
|
|||||||
options.overrideDetails = !!reqBody.overrideDetails
|
options.overrideDetails = !!reqBody.overrideDetails
|
||||||
}
|
}
|
||||||
|
|
||||||
var matchResult = await Scanner.quickMatchLibraryItem(this, libraryItem, options)
|
const matchResult = await Scanner.quickMatchLibraryItem(this, req.libraryItem, options)
|
||||||
res.json(matchResult)
|
res.json(matchResult)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -496,11 +535,11 @@ class LibraryItemController {
|
|||||||
const hardDelete = req.query.hard == 1 // Delete files from filesystem
|
const hardDelete = req.query.hard == 1 // Delete files from filesystem
|
||||||
|
|
||||||
const { libraryItemIds } = req.body
|
const { libraryItemIds } = req.body
|
||||||
if (!libraryItemIds?.length) {
|
if (!libraryItemIds?.length || !Array.isArray(libraryItemIds)) {
|
||||||
return res.status(400).send('Invalid request body')
|
return res.status(400).send('Invalid request body')
|
||||||
}
|
}
|
||||||
|
|
||||||
const itemsToDelete = await Database.libraryItemModel.getAllOldLibraryItems({
|
const itemsToDelete = await Database.libraryItemModel.findAllExpandedWhere({
|
||||||
id: libraryItemIds
|
id: libraryItemIds
|
||||||
})
|
})
|
||||||
|
|
||||||
@ -511,19 +550,19 @@ class LibraryItemController {
|
|||||||
const libraryId = itemsToDelete[0].libraryId
|
const libraryId = itemsToDelete[0].libraryId
|
||||||
for (const libraryItem of itemsToDelete) {
|
for (const libraryItem of itemsToDelete) {
|
||||||
const libraryItemPath = libraryItem.path
|
const libraryItemPath = libraryItem.path
|
||||||
Logger.info(`[LibraryItemController] (${hardDelete ? 'Hard' : 'Soft'}) deleting Library Item "${libraryItem.media.metadata.title}" with id "${libraryItem.id}"`)
|
Logger.info(`[LibraryItemController] (${hardDelete ? 'Hard' : 'Soft'}) deleting Library Item "${libraryItem.media.title}" with id "${libraryItem.id}"`)
|
||||||
const mediaItemIds = []
|
const mediaItemIds = []
|
||||||
const seriesIds = []
|
const seriesIds = []
|
||||||
const authorIds = []
|
const authorIds = []
|
||||||
if (libraryItem.isPodcast) {
|
if (libraryItem.isPodcast) {
|
||||||
mediaItemIds.push(...libraryItem.media.episodes.map((ep) => ep.id))
|
mediaItemIds.push(...libraryItem.media.podcastEpisodes.map((ep) => ep.id))
|
||||||
} else {
|
} else {
|
||||||
mediaItemIds.push(libraryItem.media.id)
|
mediaItemIds.push(libraryItem.media.id)
|
||||||
if (libraryItem.media.metadata.series?.length) {
|
if (libraryItem.media.series?.length) {
|
||||||
seriesIds.push(...libraryItem.media.metadata.series.map((se) => se.id))
|
seriesIds.push(...libraryItem.media.series.map((se) => se.id))
|
||||||
}
|
}
|
||||||
if (libraryItem.media.metadata.authors?.length) {
|
if (libraryItem.media.authors?.length) {
|
||||||
authorIds.push(...libraryItem.media.metadata.authors.map((au) => au.id))
|
authorIds.push(...libraryItem.media.authors.map((au) => au.id))
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
await this.handleDeleteLibraryItem(libraryItem.id, mediaItemIds)
|
await this.handleDeleteLibraryItem(libraryItem.id, mediaItemIds)
|
||||||
@ -568,7 +607,7 @@ class LibraryItemController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Get all library items to update
|
// Get all library items to update
|
||||||
const libraryItems = await Database.libraryItemModel.getAllOldLibraryItems({
|
const libraryItems = await Database.libraryItemModel.findAllExpandedWhere({
|
||||||
id: libraryItemIds
|
id: libraryItemIds
|
||||||
})
|
})
|
||||||
if (updatePayloads.length !== libraryItems.length) {
|
if (updatePayloads.length !== libraryItems.length) {
|
||||||
@ -585,26 +624,46 @@ class LibraryItemController {
|
|||||||
const mediaPayload = updatePayload.mediaPayload
|
const mediaPayload = updatePayload.mediaPayload
|
||||||
const libraryItem = libraryItems.find((li) => li.id === updatePayload.id)
|
const libraryItem = libraryItems.find((li) => li.id === updatePayload.id)
|
||||||
|
|
||||||
await this.createAuthorsAndSeriesForItemUpdate(mediaPayload, libraryItem.libraryId)
|
let hasUpdates = await libraryItem.media.updateFromRequest(mediaPayload)
|
||||||
|
|
||||||
if (libraryItem.isBook) {
|
if (libraryItem.isBook && Array.isArray(mediaPayload.metadata?.series)) {
|
||||||
if (Array.isArray(mediaPayload.metadata?.series)) {
|
const seriesUpdateData = await libraryItem.media.updateSeriesFromRequest(mediaPayload.metadata.series, libraryItem.libraryId)
|
||||||
const seriesIdsInUpdate = mediaPayload.metadata.series.map((se) => se.id)
|
if (seriesUpdateData?.seriesRemoved.length) {
|
||||||
const seriesRemoved = libraryItem.media.metadata.series.filter((se) => !seriesIdsInUpdate.includes(se.id))
|
seriesIdsRemoved.push(...seriesUpdateData.seriesRemoved.map((se) => se.id))
|
||||||
seriesIdsRemoved.push(...seriesRemoved.map((se) => se.id))
|
|
||||||
}
|
}
|
||||||
if (Array.isArray(mediaPayload.metadata?.authors)) {
|
if (seriesUpdateData?.seriesAdded.length) {
|
||||||
const authorIdsInUpdate = mediaPayload.metadata.authors.map((au) => au.id)
|
seriesUpdateData.seriesAdded.forEach((se) => {
|
||||||
const authorsRemoved = libraryItem.media.metadata.authors.filter((au) => !authorIdsInUpdate.includes(au.id))
|
Database.addSeriesToFilterData(libraryItem.libraryId, se.name, se.id)
|
||||||
authorIdsRemoved.push(...authorsRemoved.map((au) => au.id))
|
})
|
||||||
|
}
|
||||||
|
if (seriesUpdateData?.hasUpdates) {
|
||||||
|
hasUpdates = true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (libraryItem.media.update(mediaPayload)) {
|
if (libraryItem.isBook && Array.isArray(mediaPayload.metadata?.authors)) {
|
||||||
Logger.debug(`[LibraryItemController] Updated library item media ${libraryItem.media.metadata.title}`)
|
const authorNames = mediaPayload.metadata.authors.map((au) => (typeof au.name === 'string' ? au.name.trim() : null)).filter((au) => au)
|
||||||
|
const authorUpdateData = await libraryItem.media.updateAuthorsFromRequest(authorNames, libraryItem.libraryId)
|
||||||
|
if (authorUpdateData?.authorsRemoved.length) {
|
||||||
|
authorIdsRemoved.push(...authorUpdateData.authorsRemoved.map((au) => au.id))
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
if (authorUpdateData?.authorsAdded.length) {
|
||||||
|
authorUpdateData.authorsAdded.forEach((au) => {
|
||||||
|
Database.addAuthorToFilterData(libraryItem.libraryId, au.name, au.id)
|
||||||
|
})
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
await Database.updateLibraryItem(libraryItem)
|
if (hasUpdates) {
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
libraryItem.changed('updatedAt', true)
|
||||||
|
await libraryItem.save()
|
||||||
|
|
||||||
|
await libraryItem.saveMetadataFile()
|
||||||
|
|
||||||
|
Logger.debug(`[LibraryItemController] Updated library item media "${libraryItem.media.title}"`)
|
||||||
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
itemsUpdated++
|
itemsUpdated++
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -633,11 +692,11 @@ class LibraryItemController {
|
|||||||
if (!libraryItemIds.length) {
|
if (!libraryItemIds.length) {
|
||||||
return res.status(403).send('Invalid payload')
|
return res.status(403).send('Invalid payload')
|
||||||
}
|
}
|
||||||
const libraryItems = await Database.libraryItemModel.getAllOldLibraryItems({
|
const libraryItems = await Database.libraryItemModel.findAllExpandedWhere({
|
||||||
id: libraryItemIds
|
id: libraryItemIds
|
||||||
})
|
})
|
||||||
res.json({
|
res.json({
|
||||||
libraryItems: libraryItems.map((li) => li.toJSONExpanded())
|
libraryItems: libraryItems.map((li) => li.toOldJSONExpanded())
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -660,7 +719,7 @@ class LibraryItemController {
|
|||||||
return res.sendStatus(400)
|
return res.sendStatus(400)
|
||||||
}
|
}
|
||||||
|
|
||||||
const libraryItems = await Database.libraryItemModel.getAllOldLibraryItems({
|
const libraryItems = await Database.libraryItemModel.findAllExpandedWhere({
|
||||||
id: req.body.libraryItemIds
|
id: req.body.libraryItemIds
|
||||||
})
|
})
|
||||||
if (!libraryItems?.length) {
|
if (!libraryItems?.length) {
|
||||||
@ -741,7 +800,7 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* POST: /api/items/:id/scan
|
* POST: /api/items/:id/scan
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async scan(req, res) {
|
async scan(req, res) {
|
||||||
@ -765,7 +824,7 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* GET: /api/items/:id/metadata-object
|
* GET: /api/items/:id/metadata-object
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
getMetadataObject(req, res) {
|
getMetadataObject(req, res) {
|
||||||
@ -774,7 +833,7 @@ class LibraryItemController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (req.libraryItem.isMissing || !req.libraryItem.hasAudioFiles || !req.libraryItem.isBook) {
|
if (req.libraryItem.isMissing || !req.libraryItem.isBook || !req.libraryItem.media.includedAudioFiles.length) {
|
||||||
Logger.error(`[LibraryItemController] Invalid library item`)
|
Logger.error(`[LibraryItemController] Invalid library item`)
|
||||||
return res.sendStatus(500)
|
return res.sendStatus(500)
|
||||||
}
|
}
|
||||||
@ -785,7 +844,7 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* POST: /api/items/:id/chapters
|
* POST: /api/items/:id/chapters
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async updateMediaChapters(req, res) {
|
async updateMediaChapters(req, res) {
|
||||||
@ -794,26 +853,53 @@ class LibraryItemController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (req.libraryItem.isMissing || !req.libraryItem.hasAudioFiles || !req.libraryItem.isBook) {
|
if (req.libraryItem.isMissing || !req.libraryItem.isBook || !req.libraryItem.media.hasAudioTracks) {
|
||||||
Logger.error(`[LibraryItemController] Invalid library item`)
|
Logger.error(`[LibraryItemController] Invalid library item`)
|
||||||
return res.sendStatus(500)
|
return res.sendStatus(500)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!req.body.chapters) {
|
if (!Array.isArray(req.body.chapters) || req.body.chapters.some((c) => !c.title || typeof c.title !== 'string' || c.start === undefined || typeof c.start !== 'number' || c.end === undefined || typeof c.end !== 'number')) {
|
||||||
Logger.error(`[LibraryItemController] Invalid payload`)
|
Logger.error(`[LibraryItemController] Invalid payload`)
|
||||||
return res.sendStatus(400)
|
return res.sendStatus(400)
|
||||||
}
|
}
|
||||||
|
|
||||||
const chapters = req.body.chapters || []
|
const chapters = req.body.chapters || []
|
||||||
const wasUpdated = req.libraryItem.media.updateChapters(chapters)
|
|
||||||
if (wasUpdated) {
|
let hasUpdates = false
|
||||||
await Database.updateLibraryItem(req.libraryItem)
|
if (chapters.length !== req.libraryItem.media.chapters.length) {
|
||||||
SocketAuthority.emitter('item_updated', req.libraryItem.toJSONExpanded())
|
req.libraryItem.media.chapters = chapters.map((c, index) => {
|
||||||
|
return {
|
||||||
|
id: index,
|
||||||
|
title: c.title,
|
||||||
|
start: c.start,
|
||||||
|
end: c.end
|
||||||
|
}
|
||||||
|
})
|
||||||
|
hasUpdates = true
|
||||||
|
} else {
|
||||||
|
for (const [index, chapter] of chapters.entries()) {
|
||||||
|
const currentChapter = req.libraryItem.media.chapters[index]
|
||||||
|
if (currentChapter.title !== chapter.title || currentChapter.start !== chapter.start || currentChapter.end !== chapter.end) {
|
||||||
|
currentChapter.title = chapter.title
|
||||||
|
currentChapter.start = chapter.start
|
||||||
|
currentChapter.end = chapter.end
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hasUpdates) {
|
||||||
|
req.libraryItem.media.changed('chapters', true)
|
||||||
|
await req.libraryItem.media.save()
|
||||||
|
|
||||||
|
await req.libraryItem.saveMetadataFile()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
}
|
}
|
||||||
|
|
||||||
res.json({
|
res.json({
|
||||||
success: true,
|
success: true,
|
||||||
updated: wasUpdated
|
updated: hasUpdates
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -821,7 +907,7 @@ class LibraryItemController {
|
|||||||
* GET: /api/items/:id/ffprobe/:fileid
|
* GET: /api/items/:id/ffprobe/:fileid
|
||||||
* FFProbe JSON result from audio file
|
* FFProbe JSON result from audio file
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async getFFprobeData(req, res) {
|
async getFFprobeData(req, res) {
|
||||||
@ -829,25 +915,21 @@ class LibraryItemController {
|
|||||||
Logger.error(`[LibraryItemController] Non-admin user "${req.user.username}" attempted to get ffprobe data`)
|
Logger.error(`[LibraryItemController] Non-admin user "${req.user.username}" attempted to get ffprobe data`)
|
||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
if (req.libraryFile.fileType !== 'audio') {
|
|
||||||
Logger.error(`[LibraryItemController] Invalid filetype "${req.libraryFile.fileType}" for fileid "${req.params.fileid}". Expected audio file`)
|
|
||||||
return res.sendStatus(400)
|
|
||||||
}
|
|
||||||
|
|
||||||
const audioFile = req.libraryItem.media.findFileWithInode(req.params.fileid)
|
const audioFile = req.libraryItem.getAudioFileWithIno(req.params.fileid)
|
||||||
if (!audioFile) {
|
if (!audioFile) {
|
||||||
Logger.error(`[LibraryItemController] Audio file not found with inode value ${req.params.fileid}`)
|
Logger.error(`[LibraryItemController] Audio file not found with inode value ${req.params.fileid}`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
|
|
||||||
const ffprobeData = await AudioFileScanner.probeAudioFile(audioFile)
|
const ffprobeData = await AudioFileScanner.probeAudioFile(audioFile.metadata.path)
|
||||||
res.json(ffprobeData)
|
res.json(ffprobeData)
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* GET api/items/:id/file/:fileid
|
* GET api/items/:id/file/:fileid
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequestWithFile} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async getLibraryFile(req, res) {
|
async getLibraryFile(req, res) {
|
||||||
@ -870,7 +952,7 @@ class LibraryItemController {
|
|||||||
/**
|
/**
|
||||||
* DELETE api/items/:id/file/:fileid
|
* DELETE api/items/:id/file/:fileid
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequestWithFile} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async deleteLibraryFile(req, res) {
|
async deleteLibraryFile(req, res) {
|
||||||
@ -881,17 +963,49 @@ class LibraryItemController {
|
|||||||
await fs.remove(libraryFile.metadata.path).catch((error) => {
|
await fs.remove(libraryFile.metadata.path).catch((error) => {
|
||||||
Logger.error(`[LibraryItemController] Failed to delete library file at "${libraryFile.metadata.path}"`, error)
|
Logger.error(`[LibraryItemController] Failed to delete library file at "${libraryFile.metadata.path}"`, error)
|
||||||
})
|
})
|
||||||
req.libraryItem.removeLibraryFile(req.params.fileid)
|
|
||||||
|
|
||||||
if (req.libraryItem.media.removeFileWithInode(req.params.fileid)) {
|
req.libraryItem.libraryFiles = req.libraryItem.libraryFiles.filter((lf) => lf.ino !== req.params.fileid)
|
||||||
// If book has no more media files then mark it as missing
|
req.libraryItem.changed('libraryFiles', true)
|
||||||
if (req.libraryItem.mediaType === 'book' && !req.libraryItem.media.hasMediaEntities) {
|
|
||||||
req.libraryItem.setMissing()
|
if (req.libraryItem.isBook) {
|
||||||
|
if (req.libraryItem.media.audioFiles.some((af) => af.ino === req.params.fileid)) {
|
||||||
|
req.libraryItem.media.audioFiles = req.libraryItem.media.audioFiles.filter((af) => af.ino !== req.params.fileid)
|
||||||
|
req.libraryItem.media.changed('audioFiles', true)
|
||||||
|
} else if (req.libraryItem.media.ebookFile?.ino === req.params.fileid) {
|
||||||
|
req.libraryItem.media.ebookFile = null
|
||||||
|
req.libraryItem.media.changed('ebookFile', true)
|
||||||
}
|
}
|
||||||
|
if (!req.libraryItem.media.hasMediaFiles) {
|
||||||
|
req.libraryItem.isMissing = true
|
||||||
|
}
|
||||||
|
} else if (req.libraryItem.media.podcastEpisodes.some((ep) => ep.audioFile.ino === req.params.fileid)) {
|
||||||
|
const episodeToRemove = req.libraryItem.media.podcastEpisodes.find((ep) => ep.audioFile.ino === req.params.fileid)
|
||||||
|
// Remove episode from all playlists
|
||||||
|
await Database.playlistModel.removeMediaItemsFromPlaylists([episodeToRemove.id])
|
||||||
|
|
||||||
|
// Remove episode media progress
|
||||||
|
const numProgressRemoved = await Database.mediaProgressModel.destroy({
|
||||||
|
where: {
|
||||||
|
mediaItemId: episodeToRemove.id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if (numProgressRemoved > 0) {
|
||||||
|
Logger.info(`[LibraryItemController] Removed media progress for episode ${episodeToRemove.id}`)
|
||||||
|
}
|
||||||
|
|
||||||
|
// Remove episode
|
||||||
|
await episodeToRemove.destroy()
|
||||||
|
|
||||||
|
req.libraryItem.media.podcastEpisodes = req.libraryItem.media.podcastEpisodes.filter((ep) => ep.audioFile.ino !== req.params.fileid)
|
||||||
}
|
}
|
||||||
req.libraryItem.updatedAt = Date.now()
|
|
||||||
await Database.updateLibraryItem(req.libraryItem)
|
if (req.libraryItem.media.changed()) {
|
||||||
SocketAuthority.emitter('item_updated', req.libraryItem.toJSONExpanded())
|
await req.libraryItem.media.save()
|
||||||
|
}
|
||||||
|
|
||||||
|
await req.libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
res.sendStatus(200)
|
res.sendStatus(200)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -899,7 +1013,7 @@ class LibraryItemController {
|
|||||||
* GET api/items/:id/file/:fileid/download
|
* GET api/items/:id/file/:fileid/download
|
||||||
* Same as GET api/items/:id/file/:fileid but allows logging and restricting downloads
|
* Same as GET api/items/:id/file/:fileid but allows logging and restricting downloads
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequestWithFile} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async downloadLibraryFile(req, res) {
|
async downloadLibraryFile(req, res) {
|
||||||
@ -911,7 +1025,7 @@ class LibraryItemController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
Logger.info(`[LibraryItemController] User "${req.user.username}" requested download for item "${req.libraryItem.media.metadata.title}" file at "${libraryFile.metadata.path}"`)
|
Logger.info(`[LibraryItemController] User "${req.user.username}" requested download for item "${req.libraryItem.media.title}" file at "${libraryFile.metadata.path}"`)
|
||||||
|
|
||||||
if (global.XAccel) {
|
if (global.XAccel) {
|
||||||
const encodedURI = encodeUriPath(global.XAccel + libraryFile.metadata.path)
|
const encodedURI = encodeUriPath(global.XAccel + libraryFile.metadata.path)
|
||||||
@ -947,13 +1061,13 @@ class LibraryItemController {
|
|||||||
* fileid is only required when reading a supplementary ebook
|
* fileid is only required when reading a supplementary ebook
|
||||||
* when no fileid is passed in the primary ebook will be returned
|
* when no fileid is passed in the primary ebook will be returned
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequest} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async getEBookFile(req, res) {
|
async getEBookFile(req, res) {
|
||||||
let ebookFile = null
|
let ebookFile = null
|
||||||
if (req.params.fileid) {
|
if (req.params.fileid) {
|
||||||
ebookFile = req.libraryItem.libraryFiles.find((lf) => lf.ino === req.params.fileid)
|
ebookFile = req.libraryItem.getLibraryFileWithIno(req.params.fileid)
|
||||||
if (!ebookFile?.isEBookFile) {
|
if (!ebookFile?.isEBookFile) {
|
||||||
Logger.error(`[LibraryItemController] Invalid ebook file id "${req.params.fileid}"`)
|
Logger.error(`[LibraryItemController] Invalid ebook file id "${req.params.fileid}"`)
|
||||||
return res.status(400).send('Invalid ebook file id')
|
return res.status(400).send('Invalid ebook file id')
|
||||||
@ -963,12 +1077,12 @@ class LibraryItemController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!ebookFile) {
|
if (!ebookFile) {
|
||||||
Logger.error(`[LibraryItemController] No ebookFile for library item "${req.libraryItem.media.metadata.title}"`)
|
Logger.error(`[LibraryItemController] No ebookFile for library item "${req.libraryItem.media.title}"`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
const ebookFilePath = ebookFile.metadata.path
|
const ebookFilePath = ebookFile.metadata.path
|
||||||
|
|
||||||
Logger.info(`[LibraryItemController] User "${req.user.username}" requested download for item "${req.libraryItem.media.metadata.title}" ebook at "${ebookFilePath}"`)
|
Logger.info(`[LibraryItemController] User "${req.user.username}" requested download for item "${req.libraryItem.media.title}" ebook at "${ebookFilePath}"`)
|
||||||
|
|
||||||
if (global.XAccel) {
|
if (global.XAccel) {
|
||||||
const encodedURI = encodeUriPath(global.XAccel + ebookFilePath)
|
const encodedURI = encodeUriPath(global.XAccel + ebookFilePath)
|
||||||
@ -991,28 +1105,55 @@ class LibraryItemController {
|
|||||||
* if an ebook file is the primary ebook, then it will be changed to supplementary
|
* if an ebook file is the primary ebook, then it will be changed to supplementary
|
||||||
* if an ebook file is supplementary, then it will be changed to primary
|
* if an ebook file is supplementary, then it will be changed to primary
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {LibraryItemControllerRequestWithFile} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async updateEbookFileStatus(req, res) {
|
async updateEbookFileStatus(req, res) {
|
||||||
const ebookLibraryFile = req.libraryItem.libraryFiles.find((lf) => lf.ino === req.params.fileid)
|
if (!req.libraryItem.isBook) {
|
||||||
if (!ebookLibraryFile?.isEBookFile) {
|
Logger.error(`[LibraryItemController] Invalid media type for ebook file status update`)
|
||||||
|
return res.sendStatus(400)
|
||||||
|
}
|
||||||
|
if (!req.libraryFile?.isEBookFile) {
|
||||||
Logger.error(`[LibraryItemController] Invalid ebook file id "${req.params.fileid}"`)
|
Logger.error(`[LibraryItemController] Invalid ebook file id "${req.params.fileid}"`)
|
||||||
return res.status(400).send('Invalid ebook file id')
|
return res.status(400).send('Invalid ebook file id')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const ebookLibraryFile = req.libraryFile
|
||||||
|
let primaryEbookFile = null
|
||||||
|
|
||||||
|
const ebookLibraryFileInos = req.libraryItem
|
||||||
|
.getLibraryFiles()
|
||||||
|
.filter((lf) => lf.isEBookFile)
|
||||||
|
.map((lf) => lf.ino)
|
||||||
|
|
||||||
if (ebookLibraryFile.isSupplementary) {
|
if (ebookLibraryFile.isSupplementary) {
|
||||||
Logger.info(`[LibraryItemController] Updating ebook file "${ebookLibraryFile.metadata.filename}" to primary`)
|
Logger.info(`[LibraryItemController] Updating ebook file "${ebookLibraryFile.metadata.filename}" to primary`)
|
||||||
req.libraryItem.setPrimaryEbook(ebookLibraryFile)
|
|
||||||
|
primaryEbookFile = ebookLibraryFile.toJSON()
|
||||||
|
delete primaryEbookFile.isSupplementary
|
||||||
|
delete primaryEbookFile.fileType
|
||||||
|
primaryEbookFile.ebookFormat = ebookLibraryFile.metadata.format
|
||||||
} else {
|
} else {
|
||||||
Logger.info(`[LibraryItemController] Updating ebook file "${ebookLibraryFile.metadata.filename}" to supplementary`)
|
Logger.info(`[LibraryItemController] Updating ebook file "${ebookLibraryFile.metadata.filename}" to supplementary`)
|
||||||
ebookLibraryFile.isSupplementary = true
|
|
||||||
req.libraryItem.setPrimaryEbook(null)
|
|
||||||
}
|
}
|
||||||
|
|
||||||
req.libraryItem.updatedAt = Date.now()
|
req.libraryItem.media.ebookFile = primaryEbookFile
|
||||||
await Database.updateLibraryItem(req.libraryItem)
|
req.libraryItem.media.changed('ebookFile', true)
|
||||||
SocketAuthority.emitter('item_updated', req.libraryItem.toJSONExpanded())
|
await req.libraryItem.media.save()
|
||||||
|
|
||||||
|
req.libraryItem.libraryFiles = req.libraryItem.libraryFiles.map((lf) => {
|
||||||
|
if (ebookLibraryFileInos.includes(lf.ino)) {
|
||||||
|
lf.isSupplementary = lf.ino !== primaryEbookFile?.ino
|
||||||
|
}
|
||||||
|
return lf
|
||||||
|
})
|
||||||
|
req.libraryItem.changed('libraryFiles', true)
|
||||||
|
|
||||||
|
req.libraryItem.isMissing = !req.libraryItem.media.hasMediaFiles
|
||||||
|
|
||||||
|
await req.libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
res.sendStatus(200)
|
res.sendStatus(200)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1023,7 +1164,7 @@ class LibraryItemController {
|
|||||||
* @param {NextFunction} next
|
* @param {NextFunction} next
|
||||||
*/
|
*/
|
||||||
async middleware(req, res, next) {
|
async middleware(req, res, next) {
|
||||||
req.libraryItem = await Database.libraryItemModel.getOldById(req.params.id)
|
req.libraryItem = await Database.libraryItemModel.getExpandedById(req.params.id)
|
||||||
if (!req.libraryItem?.media) return res.sendStatus(404)
|
if (!req.libraryItem?.media) return res.sendStatus(404)
|
||||||
|
|
||||||
// Check user can access this library item
|
// Check user can access this library item
|
||||||
@ -1033,7 +1174,7 @@ class LibraryItemController {
|
|||||||
|
|
||||||
// For library file routes, get the library file
|
// For library file routes, get the library file
|
||||||
if (req.params.fileid) {
|
if (req.params.fileid) {
|
||||||
req.libraryFile = req.libraryItem.libraryFiles.find((lf) => lf.ino === req.params.fileid)
|
req.libraryFile = req.libraryItem.getLibraryFileWithIno(req.params.fileid)
|
||||||
if (!req.libraryFile) {
|
if (!req.libraryFile) {
|
||||||
Logger.error(`[LibraryItemController] Library file "${req.params.fileid}" does not exist for library item`)
|
Logger.error(`[LibraryItemController] Library file "${req.params.fileid}" does not exist for library item`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
|
@ -66,7 +66,7 @@ class MeController {
|
|||||||
const libraryItem = await Database.libraryItemModel.findByPk(req.params.libraryItemId)
|
const libraryItem = await Database.libraryItemModel.findByPk(req.params.libraryItemId)
|
||||||
const episode = await Database.podcastEpisodeModel.findByPk(req.params.episodeId)
|
const episode = await Database.podcastEpisodeModel.findByPk(req.params.episodeId)
|
||||||
|
|
||||||
if (!libraryItem || (libraryItem.mediaType === 'podcast' && !episode)) {
|
if (!libraryItem || (libraryItem.isPodcast && !episode)) {
|
||||||
Logger.error(`[MeController] Media item not found for library item id "${req.params.libraryItemId}"`)
|
Logger.error(`[MeController] Media item not found for library item id "${req.params.libraryItemId}"`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
@ -296,7 +296,7 @@ class MeController {
|
|||||||
const mediaProgressesInProgress = req.user.mediaProgresses.filter((mp) => !mp.isFinished && (mp.currentTime > 0 || mp.ebookProgress > 0))
|
const mediaProgressesInProgress = req.user.mediaProgresses.filter((mp) => !mp.isFinished && (mp.currentTime > 0 || mp.ebookProgress > 0))
|
||||||
|
|
||||||
const libraryItemsIds = [...new Set(mediaProgressesInProgress.map((mp) => mp.extraData?.libraryItemId).filter((id) => id))]
|
const libraryItemsIds = [...new Set(mediaProgressesInProgress.map((mp) => mp.extraData?.libraryItemId).filter((id) => id))]
|
||||||
const libraryItems = await Database.libraryItemModel.getAllOldLibraryItems({ id: libraryItemsIds })
|
const libraryItems = await Database.libraryItemModel.findAllExpandedWhere({ id: libraryItemsIds })
|
||||||
|
|
||||||
let itemsInProgress = []
|
let itemsInProgress = []
|
||||||
|
|
||||||
@ -304,19 +304,19 @@ class MeController {
|
|||||||
const oldMediaProgress = mediaProgress.getOldMediaProgress()
|
const oldMediaProgress = mediaProgress.getOldMediaProgress()
|
||||||
const libraryItem = libraryItems.find((li) => li.id === oldMediaProgress.libraryItemId)
|
const libraryItem = libraryItems.find((li) => li.id === oldMediaProgress.libraryItemId)
|
||||||
if (libraryItem) {
|
if (libraryItem) {
|
||||||
if (oldMediaProgress.episodeId && libraryItem.mediaType === 'podcast') {
|
if (oldMediaProgress.episodeId && libraryItem.isPodcast) {
|
||||||
const episode = libraryItem.media.episodes.find((ep) => ep.id === oldMediaProgress.episodeId)
|
const episode = libraryItem.media.podcastEpisodes.find((ep) => ep.id === oldMediaProgress.episodeId)
|
||||||
if (episode) {
|
if (episode) {
|
||||||
const libraryItemWithEpisode = {
|
const libraryItemWithEpisode = {
|
||||||
...libraryItem.toJSONMinified(),
|
...libraryItem.toOldJSONMinified(),
|
||||||
recentEpisode: episode.toJSON(),
|
recentEpisode: episode.toOldJSON(libraryItem.id),
|
||||||
progressLastUpdate: oldMediaProgress.lastUpdate
|
progressLastUpdate: oldMediaProgress.lastUpdate
|
||||||
}
|
}
|
||||||
itemsInProgress.push(libraryItemWithEpisode)
|
itemsInProgress.push(libraryItemWithEpisode)
|
||||||
}
|
}
|
||||||
} else if (!oldMediaProgress.episodeId) {
|
} else if (!oldMediaProgress.episodeId) {
|
||||||
itemsInProgress.push({
|
itemsInProgress.push({
|
||||||
...libraryItem.toJSONMinified(),
|
...libraryItem.toOldJSONMinified(),
|
||||||
progressLastUpdate: oldMediaProgress.lastUpdate
|
progressLastUpdate: oldMediaProgress.lastUpdate
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
@ -342,8 +342,8 @@ class MiscController {
|
|||||||
tags: libraryItem.media.tags
|
tags: libraryItem.media.tags
|
||||||
})
|
})
|
||||||
await libraryItem.saveMetadataFile()
|
await libraryItem.saveMetadataFile()
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', oldLibraryItem.toJSONExpanded())
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
numItemsUpdated++
|
numItemsUpdated++
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -385,8 +385,8 @@ class MiscController {
|
|||||||
tags: libraryItem.media.tags
|
tags: libraryItem.media.tags
|
||||||
})
|
})
|
||||||
await libraryItem.saveMetadataFile()
|
await libraryItem.saveMetadataFile()
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', oldLibraryItem.toJSONExpanded())
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
numItemsUpdated++
|
numItemsUpdated++
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -480,8 +480,8 @@ class MiscController {
|
|||||||
genres: libraryItem.media.genres
|
genres: libraryItem.media.genres
|
||||||
})
|
})
|
||||||
await libraryItem.saveMetadataFile()
|
await libraryItem.saveMetadataFile()
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', oldLibraryItem.toJSONExpanded())
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
numItemsUpdated++
|
numItemsUpdated++
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -523,8 +523,8 @@ class MiscController {
|
|||||||
genres: libraryItem.media.genres
|
genres: libraryItem.media.genres
|
||||||
})
|
})
|
||||||
await libraryItem.saveMetadataFile()
|
await libraryItem.saveMetadataFile()
|
||||||
const oldLibraryItem = Database.libraryItemModel.getOldLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', oldLibraryItem.toJSONExpanded())
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
numItemsUpdated++
|
numItemsUpdated++
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -276,7 +276,7 @@ class PlaylistController {
|
|||||||
return res.status(400).send('Request body has no libraryItemId')
|
return res.status(400).send('Request body has no libraryItemId')
|
||||||
}
|
}
|
||||||
|
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(itemToAdd.libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(itemToAdd.libraryItemId)
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
return res.status(400).send('Library item not found')
|
return res.status(400).send('Library item not found')
|
||||||
}
|
}
|
||||||
@ -286,7 +286,7 @@ class PlaylistController {
|
|||||||
if ((itemToAdd.episodeId && !libraryItem.isPodcast) || (libraryItem.isPodcast && !itemToAdd.episodeId)) {
|
if ((itemToAdd.episodeId && !libraryItem.isPodcast) || (libraryItem.isPodcast && !itemToAdd.episodeId)) {
|
||||||
return res.status(400).send('Invalid item to add for this library type')
|
return res.status(400).send('Invalid item to add for this library type')
|
||||||
}
|
}
|
||||||
if (itemToAdd.episodeId && !libraryItem.media.checkHasEpisode(itemToAdd.episodeId)) {
|
if (itemToAdd.episodeId && !libraryItem.media.podcastEpisodes.some((pe) => pe.id === itemToAdd.episodeId)) {
|
||||||
return res.status(400).send('Episode not found in library item')
|
return res.status(400).send('Episode not found in library item')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -308,17 +308,17 @@ class PlaylistController {
|
|||||||
|
|
||||||
// Add the new item to to the old json expanded to prevent having to fully reload the playlist media items
|
// Add the new item to to the old json expanded to prevent having to fully reload the playlist media items
|
||||||
if (itemToAdd.episodeId) {
|
if (itemToAdd.episodeId) {
|
||||||
const episode = libraryItem.media.episodes.find((ep) => ep.id === itemToAdd.episodeId)
|
const episode = libraryItem.media.podcastEpisodes.find((ep) => ep.id === itemToAdd.episodeId)
|
||||||
jsonExpanded.items.push({
|
jsonExpanded.items.push({
|
||||||
episodeId: itemToAdd.episodeId,
|
episodeId: itemToAdd.episodeId,
|
||||||
episode: episode.toJSONExpanded(),
|
episode: episode.toOldJSONExpanded(libraryItem.id),
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItem: libraryItem.toJSONMinified()
|
libraryItem: libraryItem.toOldJSONMinified()
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
jsonExpanded.items.push({
|
jsonExpanded.items.push({
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItem: libraryItem.toJSONExpanded()
|
libraryItem: libraryItem.toOldJSONExpanded()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -388,8 +388,8 @@ class PlaylistController {
|
|||||||
// Find all library items
|
// Find all library items
|
||||||
const libraryItemIds = new Set(req.body.items.map((i) => i.libraryItemId).filter((i) => i))
|
const libraryItemIds = new Set(req.body.items.map((i) => i.libraryItemId).filter((i) => i))
|
||||||
|
|
||||||
const oldLibraryItems = await Database.libraryItemModel.getAllOldLibraryItems({ id: Array.from(libraryItemIds) })
|
const libraryItems = await Database.libraryItemModel.findAllExpandedWhere({ id: Array.from(libraryItemIds) })
|
||||||
if (oldLibraryItems.length !== libraryItemIds.size) {
|
if (libraryItems.length !== libraryItemIds.size) {
|
||||||
return res.status(400).send('Invalid request body items')
|
return res.status(400).send('Invalid request body items')
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -401,7 +401,7 @@ class PlaylistController {
|
|||||||
// Setup array of playlistMediaItem records to add
|
// Setup array of playlistMediaItem records to add
|
||||||
let order = req.playlist.playlistMediaItems.length + 1
|
let order = req.playlist.playlistMediaItems.length + 1
|
||||||
for (const item of req.body.items) {
|
for (const item of req.body.items) {
|
||||||
const libraryItem = oldLibraryItems.find((li) => li.id === item.libraryItemId)
|
const libraryItem = libraryItems.find((li) => li.id === item.libraryItemId)
|
||||||
|
|
||||||
const mediaItemId = item.episodeId || libraryItem.media.id
|
const mediaItemId = item.episodeId || libraryItem.media.id
|
||||||
if (req.playlist.playlistMediaItems.some((pmi) => pmi.mediaItemId === mediaItemId)) {
|
if (req.playlist.playlistMediaItems.some((pmi) => pmi.mediaItemId === mediaItemId)) {
|
||||||
@ -417,17 +417,17 @@ class PlaylistController {
|
|||||||
|
|
||||||
// Add the new item to to the old json expanded to prevent having to fully reload the playlist media items
|
// Add the new item to to the old json expanded to prevent having to fully reload the playlist media items
|
||||||
if (item.episodeId) {
|
if (item.episodeId) {
|
||||||
const episode = libraryItem.media.episodes.find((ep) => ep.id === item.episodeId)
|
const episode = libraryItem.media.podcastEpisodes.find((ep) => ep.id === item.episodeId)
|
||||||
jsonExpanded.items.push({
|
jsonExpanded.items.push({
|
||||||
episodeId: item.episodeId,
|
episodeId: item.episodeId,
|
||||||
episode: episode.toJSONExpanded(),
|
episode: episode.toOldJSONExpanded(libraryItem.id),
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItem: libraryItem.toJSONMinified()
|
libraryItem: libraryItem.toOldJSONMinified()
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
jsonExpanded.items.push({
|
jsonExpanded.items.push({
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItem: libraryItem.toJSONExpanded()
|
libraryItem: libraryItem.toOldJSONExpanded()
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
const Path = require('path')
|
||||||
const { Request, Response, NextFunction } = require('express')
|
const { Request, Response, NextFunction } = require('express')
|
||||||
const Logger = require('../Logger')
|
const Logger = require('../Logger')
|
||||||
const SocketAuthority = require('../SocketAuthority')
|
const SocketAuthority = require('../SocketAuthority')
|
||||||
@ -12,13 +13,16 @@ const { validateUrl } = require('../utils/index')
|
|||||||
const Scanner = require('../scanner/Scanner')
|
const Scanner = require('../scanner/Scanner')
|
||||||
const CoverManager = require('../managers/CoverManager')
|
const CoverManager = require('../managers/CoverManager')
|
||||||
|
|
||||||
const LibraryItem = require('../objects/LibraryItem')
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef RequestUserObject
|
* @typedef RequestUserObject
|
||||||
* @property {import('../models/User')} user
|
* @property {import('../models/User')} user
|
||||||
*
|
*
|
||||||
* @typedef {Request & RequestUserObject} RequestWithUser
|
* @typedef {Request & RequestUserObject} RequestWithUser
|
||||||
|
*
|
||||||
|
* @typedef RequestEntityObject
|
||||||
|
* @property {import('../models/LibraryItem')} libraryItem
|
||||||
|
*
|
||||||
|
* @typedef {RequestWithUser & RequestEntityObject} RequestWithLibraryItem
|
||||||
*/
|
*/
|
||||||
|
|
||||||
class PodcastController {
|
class PodcastController {
|
||||||
@ -37,6 +41,9 @@ class PodcastController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
const payload = req.body
|
const payload = req.body
|
||||||
|
if (!payload.media || !payload.media.metadata) {
|
||||||
|
return res.status(400).send('Invalid request body. "media" and "media.metadata" are required')
|
||||||
|
}
|
||||||
|
|
||||||
const library = await Database.libraryModel.findByIdWithFolders(payload.libraryId)
|
const library = await Database.libraryModel.findByIdWithFolders(payload.libraryId)
|
||||||
if (!library) {
|
if (!library) {
|
||||||
@ -78,48 +85,87 @@ class PodcastController {
|
|||||||
let relPath = payload.path.replace(folder.fullPath, '')
|
let relPath = payload.path.replace(folder.fullPath, '')
|
||||||
if (relPath.startsWith('/')) relPath = relPath.slice(1)
|
if (relPath.startsWith('/')) relPath = relPath.slice(1)
|
||||||
|
|
||||||
const libraryItemPayload = {
|
let newLibraryItem = null
|
||||||
path: podcastPath,
|
const transaction = await Database.sequelize.transaction()
|
||||||
relPath,
|
try {
|
||||||
folderId: payload.folderId,
|
const podcast = await Database.podcastModel.createFromRequest(payload.media, transaction)
|
||||||
libraryId: payload.libraryId,
|
|
||||||
ino: libraryItemFolderStats.ino,
|
newLibraryItem = await Database.libraryItemModel.create(
|
||||||
mtimeMs: libraryItemFolderStats.mtimeMs || 0,
|
{
|
||||||
ctimeMs: libraryItemFolderStats.ctimeMs || 0,
|
ino: libraryItemFolderStats.ino,
|
||||||
birthtimeMs: libraryItemFolderStats.birthtimeMs || 0,
|
path: podcastPath,
|
||||||
media: payload.media
|
relPath,
|
||||||
|
mediaId: podcast.id,
|
||||||
|
mediaType: 'podcast',
|
||||||
|
isFile: false,
|
||||||
|
isMissing: false,
|
||||||
|
isInvalid: false,
|
||||||
|
mtime: libraryItemFolderStats.mtimeMs || 0,
|
||||||
|
ctime: libraryItemFolderStats.ctimeMs || 0,
|
||||||
|
birthtime: libraryItemFolderStats.birthtimeMs || 0,
|
||||||
|
size: 0,
|
||||||
|
libraryFiles: [],
|
||||||
|
extraData: {},
|
||||||
|
libraryId: library.id,
|
||||||
|
libraryFolderId: folder.id
|
||||||
|
},
|
||||||
|
{ transaction }
|
||||||
|
)
|
||||||
|
|
||||||
|
await transaction.commit()
|
||||||
|
} catch (error) {
|
||||||
|
Logger.error(`[PodcastController] Failed to create podcast: ${error}`)
|
||||||
|
await transaction.rollback()
|
||||||
|
return res.status(500).send('Failed to create podcast')
|
||||||
}
|
}
|
||||||
|
|
||||||
const libraryItem = new LibraryItem()
|
newLibraryItem.media = await newLibraryItem.getMediaExpanded()
|
||||||
libraryItem.setData('podcast', libraryItemPayload)
|
|
||||||
|
|
||||||
// Download and save cover image
|
// Download and save cover image
|
||||||
if (payload.media.metadata.imageUrl) {
|
if (typeof payload.media.metadata.imageUrl === 'string' && payload.media.metadata.imageUrl.startsWith('http')) {
|
||||||
// TODO: Scan cover image to library files
|
|
||||||
// Podcast cover will always go into library item folder
|
// Podcast cover will always go into library item folder
|
||||||
const coverResponse = await CoverManager.downloadCoverFromUrl(libraryItem, payload.media.metadata.imageUrl, true)
|
const coverResponse = await CoverManager.downloadCoverFromUrlNew(payload.media.metadata.imageUrl, newLibraryItem.id, newLibraryItem.path, true)
|
||||||
if (coverResponse) {
|
if (coverResponse.error) {
|
||||||
if (coverResponse.error) {
|
Logger.error(`[PodcastController] Download cover error from "${payload.media.metadata.imageUrl}": ${coverResponse.error}`)
|
||||||
Logger.error(`[PodcastController] Download cover error from "${payload.media.metadata.imageUrl}": ${coverResponse.error}`)
|
} else if (coverResponse.cover) {
|
||||||
} else if (coverResponse.cover) {
|
const coverImageFileStats = await getFileTimestampsWithIno(coverResponse.cover)
|
||||||
libraryItem.media.coverPath = coverResponse.cover
|
if (!coverImageFileStats) {
|
||||||
|
Logger.error(`[PodcastController] Failed to get cover image stats for "${coverResponse.cover}"`)
|
||||||
|
} else {
|
||||||
|
// Add libraryFile to libraryItem and coverPath to podcast
|
||||||
|
const newLibraryFile = {
|
||||||
|
ino: coverImageFileStats.ino,
|
||||||
|
fileType: 'image',
|
||||||
|
addedAt: Date.now(),
|
||||||
|
updatedAt: Date.now(),
|
||||||
|
metadata: {
|
||||||
|
filename: Path.basename(coverResponse.cover),
|
||||||
|
ext: Path.extname(coverResponse.cover).slice(1),
|
||||||
|
path: coverResponse.cover,
|
||||||
|
relPath: Path.basename(coverResponse.cover),
|
||||||
|
size: coverImageFileStats.size,
|
||||||
|
mtimeMs: coverImageFileStats.mtimeMs || 0,
|
||||||
|
ctimeMs: coverImageFileStats.ctimeMs || 0,
|
||||||
|
birthtimeMs: coverImageFileStats.birthtimeMs || 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
newLibraryItem.libraryFiles.push(newLibraryFile)
|
||||||
|
newLibraryItem.changed('libraryFiles', true)
|
||||||
|
await newLibraryItem.save()
|
||||||
|
|
||||||
|
newLibraryItem.media.coverPath = coverResponse.cover
|
||||||
|
await newLibraryItem.media.save()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
await Database.createLibraryItem(libraryItem)
|
SocketAuthority.emitter('item_added', newLibraryItem.toOldJSONExpanded())
|
||||||
SocketAuthority.emitter('item_added', libraryItem.toJSONExpanded())
|
|
||||||
|
|
||||||
res.json(libraryItem.toJSONExpanded())
|
res.json(newLibraryItem.toOldJSONExpanded())
|
||||||
|
|
||||||
if (payload.episodesToDownload?.length) {
|
|
||||||
Logger.info(`[PodcastController] Podcast created now starting ${payload.episodesToDownload.length} episode downloads`)
|
|
||||||
this.podcastManager.downloadPodcastEpisodes(libraryItem, payload.episodesToDownload)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Turn on podcast auto download cron if not already on
|
// Turn on podcast auto download cron if not already on
|
||||||
if (libraryItem.media.autoDownloadEpisodes) {
|
if (newLibraryItem.media.autoDownloadEpisodes) {
|
||||||
this.cronManager.checkUpdatePodcastCron(libraryItem)
|
this.cronManager.checkUpdatePodcastCron(newLibraryItem)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -213,7 +259,7 @@ class PodcastController {
|
|||||||
*
|
*
|
||||||
* @this import('../routers/ApiRouter')
|
* @this import('../routers/ApiRouter')
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async checkNewEpisodes(req, res) {
|
async checkNewEpisodes(req, res) {
|
||||||
@ -222,15 +268,14 @@ class PodcastController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
var libraryItem = req.libraryItem
|
if (!req.libraryItem.media.feedURL) {
|
||||||
if (!libraryItem.media.metadata.feedUrl) {
|
Logger.error(`[PodcastController] checkNewEpisodes no feed url for item ${req.libraryItem.id}`)
|
||||||
Logger.error(`[PodcastController] checkNewEpisodes no feed url for item ${libraryItem.id}`)
|
return res.status(400).send('Podcast has no rss feed url')
|
||||||
return res.status(500).send('Podcast has no rss feed url')
|
|
||||||
}
|
}
|
||||||
|
|
||||||
const maxEpisodesToDownload = !isNaN(req.query.limit) ? Number(req.query.limit) : 3
|
const maxEpisodesToDownload = !isNaN(req.query.limit) ? Number(req.query.limit) : 3
|
||||||
|
|
||||||
var newEpisodes = await this.podcastManager.checkAndDownloadNewEpisodes(libraryItem, maxEpisodesToDownload)
|
const newEpisodes = await this.podcastManager.checkAndDownloadNewEpisodes(req.libraryItem, maxEpisodesToDownload)
|
||||||
res.json({
|
res.json({
|
||||||
episodes: newEpisodes || []
|
episodes: newEpisodes || []
|
||||||
})
|
})
|
||||||
@ -258,23 +303,28 @@ class PodcastController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
getEpisodeDownloads(req, res) {
|
getEpisodeDownloads(req, res) {
|
||||||
var libraryItem = req.libraryItem
|
const downloadsInQueue = this.podcastManager.getEpisodeDownloadsInQueue(req.libraryItem.id)
|
||||||
|
|
||||||
var downloadsInQueue = this.podcastManager.getEpisodeDownloadsInQueue(libraryItem.id)
|
|
||||||
res.json({
|
res.json({
|
||||||
downloads: downloadsInQueue.map((d) => d.toJSONForClient())
|
downloads: downloadsInQueue.map((d) => d.toJSONForClient())
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* GET: /api/podcasts/:id/search-episode
|
||||||
|
* Search for an episode in a podcast
|
||||||
|
*
|
||||||
|
* @param {RequestWithLibraryItem} req
|
||||||
|
* @param {Response} res
|
||||||
|
*/
|
||||||
async findEpisode(req, res) {
|
async findEpisode(req, res) {
|
||||||
const rssFeedUrl = req.libraryItem.media.metadata.feedUrl
|
const rssFeedUrl = req.libraryItem.media.feedURL
|
||||||
if (!rssFeedUrl) {
|
if (!rssFeedUrl) {
|
||||||
Logger.error(`[PodcastController] findEpisode: Podcast has no feed url`)
|
Logger.error(`[PodcastController] findEpisode: Podcast has no feed url`)
|
||||||
return res.status(500).send('Podcast does not have an RSS feed URL')
|
return res.status(400).send('Podcast does not have an RSS feed URL')
|
||||||
}
|
}
|
||||||
|
|
||||||
const searchTitle = req.query.title
|
const searchTitle = req.query.title
|
||||||
@ -292,7 +342,7 @@ class PodcastController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async downloadEpisodes(req, res) {
|
async downloadEpisodes(req, res) {
|
||||||
@ -300,13 +350,13 @@ class PodcastController {
|
|||||||
Logger.error(`[PodcastController] Non-admin user "${req.user.username}" attempted to download episodes`)
|
Logger.error(`[PodcastController] Non-admin user "${req.user.username}" attempted to download episodes`)
|
||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
const libraryItem = req.libraryItem
|
|
||||||
const episodes = req.body
|
const episodes = req.body
|
||||||
if (!episodes?.length) {
|
if (!Array.isArray(episodes) || !episodes.length) {
|
||||||
return res.sendStatus(400)
|
return res.sendStatus(400)
|
||||||
}
|
}
|
||||||
|
|
||||||
this.podcastManager.downloadPodcastEpisodes(libraryItem, episodes)
|
this.podcastManager.downloadPodcastEpisodes(req.libraryItem, episodes)
|
||||||
res.sendStatus(200)
|
res.sendStatus(200)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -315,7 +365,7 @@ class PodcastController {
|
|||||||
*
|
*
|
||||||
* @this {import('../routers/ApiRouter')}
|
* @this {import('../routers/ApiRouter')}
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async quickMatchEpisodes(req, res) {
|
async quickMatchEpisodes(req, res) {
|
||||||
@ -327,8 +377,7 @@ class PodcastController {
|
|||||||
const overrideDetails = req.query.override === '1'
|
const overrideDetails = req.query.override === '1'
|
||||||
const episodesUpdated = await Scanner.quickMatchPodcastEpisodes(req.libraryItem, { overrideDetails })
|
const episodesUpdated = await Scanner.quickMatchPodcastEpisodes(req.libraryItem, { overrideDetails })
|
||||||
if (episodesUpdated) {
|
if (episodesUpdated) {
|
||||||
await Database.updateLibraryItem(req.libraryItem)
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
SocketAuthority.emitter('item_updated', req.libraryItem.toJSONExpanded())
|
|
||||||
}
|
}
|
||||||
|
|
||||||
res.json({
|
res.json({
|
||||||
@ -339,61 +388,82 @@ class PodcastController {
|
|||||||
/**
|
/**
|
||||||
* PATCH: /api/podcasts/:id/episode/:episodeId
|
* PATCH: /api/podcasts/:id/episode/:episodeId
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async updateEpisode(req, res) {
|
async updateEpisode(req, res) {
|
||||||
const libraryItem = req.libraryItem
|
/** @type {import('../models/PodcastEpisode')} */
|
||||||
|
const episode = req.libraryItem.media.podcastEpisodes.find((ep) => ep.id === req.params.episodeId)
|
||||||
var episodeId = req.params.episodeId
|
if (!episode) {
|
||||||
if (!libraryItem.media.checkHasEpisode(episodeId)) {
|
|
||||||
return res.status(404).send('Episode not found')
|
return res.status(404).send('Episode not found')
|
||||||
}
|
}
|
||||||
|
|
||||||
if (libraryItem.media.updateEpisode(episodeId, req.body)) {
|
const updatePayload = {}
|
||||||
await Database.updateLibraryItem(libraryItem)
|
const supportedStringKeys = ['title', 'subtitle', 'description', 'pubDate', 'episode', 'season', 'episodeType']
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
for (const key in req.body) {
|
||||||
|
if (supportedStringKeys.includes(key) && typeof req.body[key] === 'string') {
|
||||||
|
updatePayload[key] = req.body[key]
|
||||||
|
} else if (key === 'chapters' && Array.isArray(req.body[key]) && req.body[key].every((ch) => typeof ch === 'object' && ch.title && ch.start)) {
|
||||||
|
updatePayload[key] = req.body[key]
|
||||||
|
} else if (key === 'publishedAt' && typeof req.body[key] === 'number') {
|
||||||
|
updatePayload[key] = req.body[key]
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
res.json(libraryItem.toJSONExpanded())
|
if (Object.keys(updatePayload).length) {
|
||||||
|
episode.set(updatePayload)
|
||||||
|
if (episode.changed()) {
|
||||||
|
Logger.info(`[PodcastController] Updated episode "${episode.title}" keys`, episode.changed())
|
||||||
|
await episode.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
|
} else {
|
||||||
|
Logger.info(`[PodcastController] No changes to episode "${episode.title}"`)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
res.json(req.libraryItem.toOldJSONExpanded())
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* GET: /api/podcasts/:id/episode/:episodeId
|
* GET: /api/podcasts/:id/episode/:episodeId
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async getEpisode(req, res) {
|
async getEpisode(req, res) {
|
||||||
const episodeId = req.params.episodeId
|
const episodeId = req.params.episodeId
|
||||||
const libraryItem = req.libraryItem
|
|
||||||
|
|
||||||
const episode = libraryItem.media.episodes.find((ep) => ep.id === episodeId)
|
/** @type {import('../models/PodcastEpisode')} */
|
||||||
|
const episode = req.libraryItem.media.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
if (!episode) {
|
if (!episode) {
|
||||||
Logger.error(`[PodcastController] getEpisode episode ${episodeId} not found for item ${libraryItem.id}`)
|
Logger.error(`[PodcastController] getEpisode episode ${episodeId} not found for item ${req.libraryItem.id}`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
|
|
||||||
res.json(episode)
|
res.json(episode.toOldJSON(req.libraryItem.id))
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* DELETE: /api/podcasts/:id/episode/:episodeId
|
* DELETE: /api/podcasts/:id/episode/:episodeId
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async removeEpisode(req, res) {
|
async removeEpisode(req, res) {
|
||||||
const episodeId = req.params.episodeId
|
const episodeId = req.params.episodeId
|
||||||
const libraryItem = req.libraryItem
|
|
||||||
const hardDelete = req.query.hard === '1'
|
const hardDelete = req.query.hard === '1'
|
||||||
|
|
||||||
const episode = libraryItem.media.episodes.find((ep) => ep.id === episodeId)
|
/** @type {import('../models/PodcastEpisode')} */
|
||||||
|
const episode = req.libraryItem.media.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
if (!episode) {
|
if (!episode) {
|
||||||
Logger.error(`[PodcastController] removeEpisode episode ${episodeId} not found for item ${libraryItem.id}`)
|
Logger.error(`[PodcastController] removeEpisode episode ${episodeId} not found for item ${req.libraryItem.id}`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Remove it from the podcastEpisodes array
|
||||||
|
req.libraryItem.media.podcastEpisodes = req.libraryItem.media.podcastEpisodes.filter((ep) => ep.id !== episodeId)
|
||||||
|
|
||||||
if (hardDelete) {
|
if (hardDelete) {
|
||||||
const audioFile = episode.audioFile
|
const audioFile = episode.audioFile
|
||||||
// TODO: this will trigger the watcher. should maybe handle this gracefully
|
// TODO: this will trigger the watcher. should maybe handle this gracefully
|
||||||
@ -407,36 +477,8 @@ class PodcastController {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
// Remove episode from Podcast and library file
|
// Remove episode from playlists
|
||||||
const episodeRemoved = libraryItem.media.removeEpisode(episodeId)
|
await Database.playlistModel.removeMediaItemsFromPlaylists([episodeId])
|
||||||
if (episodeRemoved?.audioFile) {
|
|
||||||
libraryItem.removeLibraryFile(episodeRemoved.audioFile.ino)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update/remove playlists that had this podcast episode
|
|
||||||
const playlistMediaItems = await Database.playlistMediaItemModel.findAll({
|
|
||||||
where: {
|
|
||||||
mediaItemId: episodeId
|
|
||||||
},
|
|
||||||
include: {
|
|
||||||
model: Database.playlistModel,
|
|
||||||
include: Database.playlistMediaItemModel
|
|
||||||
}
|
|
||||||
})
|
|
||||||
for (const pmi of playlistMediaItems) {
|
|
||||||
const numItems = pmi.playlist.playlistMediaItems.length - 1
|
|
||||||
|
|
||||||
if (!numItems) {
|
|
||||||
Logger.info(`[PodcastController] Playlist "${pmi.playlist.name}" has no more items - removing it`)
|
|
||||||
const jsonExpanded = await pmi.playlist.getOldJsonExpanded()
|
|
||||||
SocketAuthority.clientEmitter(pmi.playlist.userId, 'playlist_removed', jsonExpanded)
|
|
||||||
await pmi.playlist.destroy()
|
|
||||||
} else {
|
|
||||||
await pmi.destroy()
|
|
||||||
const jsonExpanded = await pmi.playlist.getOldJsonExpanded()
|
|
||||||
SocketAuthority.clientEmitter(pmi.playlist.userId, 'playlist_updated', jsonExpanded)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Remove media progress for this episode
|
// Remove media progress for this episode
|
||||||
const mediaProgressRemoved = await Database.mediaProgressModel.destroy({
|
const mediaProgressRemoved = await Database.mediaProgressModel.destroy({
|
||||||
@ -448,9 +490,16 @@ class PodcastController {
|
|||||||
Logger.info(`[PodcastController] Removed ${mediaProgressRemoved} media progress for episode ${episode.id}`)
|
Logger.info(`[PodcastController] Removed ${mediaProgressRemoved} media progress for episode ${episode.id}`)
|
||||||
}
|
}
|
||||||
|
|
||||||
await Database.updateLibraryItem(libraryItem)
|
// Remove episode
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
await episode.destroy()
|
||||||
res.json(libraryItem.toJSON())
|
|
||||||
|
// Remove library file
|
||||||
|
req.libraryItem.libraryFiles = req.libraryItem.libraryFiles.filter((file) => file.ino !== episode.audioFile.ino)
|
||||||
|
req.libraryItem.changed('libraryFiles', true)
|
||||||
|
await req.libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', req.libraryItem.toOldJSONExpanded())
|
||||||
|
res.json(req.libraryItem.toOldJSON())
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -460,15 +509,15 @@ class PodcastController {
|
|||||||
* @param {NextFunction} next
|
* @param {NextFunction} next
|
||||||
*/
|
*/
|
||||||
async middleware(req, res, next) {
|
async middleware(req, res, next) {
|
||||||
const item = await Database.libraryItemModel.getOldById(req.params.id)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(req.params.id)
|
||||||
if (!item?.media) return res.sendStatus(404)
|
if (!libraryItem?.media) return res.sendStatus(404)
|
||||||
|
|
||||||
if (!item.isPodcast) {
|
if (!libraryItem.isPodcast) {
|
||||||
return res.sendStatus(500)
|
return res.sendStatus(500)
|
||||||
}
|
}
|
||||||
|
|
||||||
// Check user can access this library item
|
// Check user can access this library item
|
||||||
if (!req.user.checkCanAccessLibraryItem(item)) {
|
if (!req.user.checkCanAccessLibraryItem(libraryItem)) {
|
||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -480,7 +529,7 @@ class PodcastController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
req.libraryItem = item
|
req.libraryItem = libraryItem
|
||||||
next()
|
next()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -24,7 +24,7 @@ class SearchController {
|
|||||||
*/
|
*/
|
||||||
async findBooks(req, res) {
|
async findBooks(req, res) {
|
||||||
const id = req.query.id
|
const id = req.query.id
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(id)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(id)
|
||||||
const provider = req.query.provider || 'google'
|
const provider = req.query.provider || 'google'
|
||||||
const title = req.query.title || ''
|
const title = req.query.title || ''
|
||||||
const author = req.query.author || ''
|
const author = req.query.author || ''
|
||||||
|
@ -149,7 +149,7 @@ class SessionController {
|
|||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async getOpenSession(req, res) {
|
async getOpenSession(req, res) {
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(req.playbackSession.libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(req.playbackSession.libraryItemId)
|
||||||
const sessionForClient = req.playbackSession.toJSONForClient(libraryItem)
|
const sessionForClient = req.playbackSession.toJSONForClient(libraryItem)
|
||||||
res.json(sessionForClient)
|
res.json(sessionForClient)
|
||||||
}
|
}
|
||||||
|
@ -70,14 +70,13 @@ class ShareController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const oldLibraryItem = await Database.mediaItemShareModel.getMediaItemsOldLibraryItem(mediaItemShare.mediaItemId, mediaItemShare.mediaItemType)
|
const libraryItem = await Database.mediaItemShareModel.getMediaItemsLibraryItem(mediaItemShare.mediaItemId, mediaItemShare.mediaItemType)
|
||||||
|
if (!libraryItem) {
|
||||||
if (!oldLibraryItem) {
|
|
||||||
return res.status(404).send('Media item not found')
|
return res.status(404).send('Media item not found')
|
||||||
}
|
}
|
||||||
|
|
||||||
let startOffset = 0
|
let startOffset = 0
|
||||||
const publicTracks = oldLibraryItem.media.includedAudioFiles.map((audioFile) => {
|
const publicTracks = libraryItem.media.includedAudioFiles.map((audioFile) => {
|
||||||
const audioTrack = {
|
const audioTrack = {
|
||||||
index: audioFile.index,
|
index: audioFile.index,
|
||||||
startOffset,
|
startOffset,
|
||||||
@ -86,7 +85,7 @@ class ShareController {
|
|||||||
contentUrl: `${global.RouterBasePath}/public/share/${slug}/track/${audioFile.index}`,
|
contentUrl: `${global.RouterBasePath}/public/share/${slug}/track/${audioFile.index}`,
|
||||||
mimeType: audioFile.mimeType,
|
mimeType: audioFile.mimeType,
|
||||||
codec: audioFile.codec || null,
|
codec: audioFile.codec || null,
|
||||||
metadata: audioFile.metadata.clone()
|
metadata: structuredClone(audioFile.metadata)
|
||||||
}
|
}
|
||||||
startOffset += audioTrack.duration
|
startOffset += audioTrack.duration
|
||||||
return audioTrack
|
return audioTrack
|
||||||
@ -105,12 +104,12 @@ class ShareController {
|
|||||||
const deviceInfo = await this.playbackSessionManager.getDeviceInfo(req, clientDeviceInfo)
|
const deviceInfo = await this.playbackSessionManager.getDeviceInfo(req, clientDeviceInfo)
|
||||||
|
|
||||||
const newPlaybackSession = new PlaybackSession()
|
const newPlaybackSession = new PlaybackSession()
|
||||||
newPlaybackSession.setData(oldLibraryItem, null, 'web-share', deviceInfo, startTime)
|
newPlaybackSession.setData(libraryItem, null, 'web-share', deviceInfo, startTime)
|
||||||
newPlaybackSession.audioTracks = publicTracks
|
newPlaybackSession.audioTracks = publicTracks
|
||||||
newPlaybackSession.playMethod = PlayMethod.DIRECTPLAY
|
newPlaybackSession.playMethod = PlayMethod.DIRECTPLAY
|
||||||
newPlaybackSession.shareSessionId = shareSessionId
|
newPlaybackSession.shareSessionId = shareSessionId
|
||||||
newPlaybackSession.mediaItemShareId = mediaItemShare.id
|
newPlaybackSession.mediaItemShareId = mediaItemShare.id
|
||||||
newPlaybackSession.coverAspectRatio = oldLibraryItem.librarySettings.coverAspectRatio
|
newPlaybackSession.coverAspectRatio = libraryItem.library.settings.coverAspectRatio
|
||||||
|
|
||||||
mediaItemShare.playbackSession = newPlaybackSession.toJSONForClient()
|
mediaItemShare.playbackSession = newPlaybackSession.toJSONForClient()
|
||||||
ShareManager.addOpenSharePlaybackSession(newPlaybackSession)
|
ShareManager.addOpenSharePlaybackSession(newPlaybackSession)
|
||||||
|
@ -7,6 +7,11 @@ const Database = require('../Database')
|
|||||||
* @property {import('../models/User')} user
|
* @property {import('../models/User')} user
|
||||||
*
|
*
|
||||||
* @typedef {Request & RequestUserObject} RequestWithUser
|
* @typedef {Request & RequestUserObject} RequestWithUser
|
||||||
|
*
|
||||||
|
* @typedef RequestEntityObject
|
||||||
|
* @property {import('../models/LibraryItem')} libraryItem
|
||||||
|
*
|
||||||
|
* @typedef {RequestWithUser & RequestEntityObject} RequestWithLibraryItem
|
||||||
*/
|
*/
|
||||||
|
|
||||||
class ToolsController {
|
class ToolsController {
|
||||||
@ -18,7 +23,7 @@ class ToolsController {
|
|||||||
*
|
*
|
||||||
* @this import('../routers/ApiRouter')
|
* @this import('../routers/ApiRouter')
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async encodeM4b(req, res) {
|
async encodeM4b(req, res) {
|
||||||
@ -27,12 +32,12 @@ class ToolsController {
|
|||||||
return res.status(404).send('Audiobook not found')
|
return res.status(404).send('Audiobook not found')
|
||||||
}
|
}
|
||||||
|
|
||||||
if (req.libraryItem.mediaType !== 'book') {
|
if (!req.libraryItem.isBook) {
|
||||||
Logger.error(`[MiscController] encodeM4b: Invalid library item ${req.params.id}: not a book`)
|
Logger.error(`[MiscController] encodeM4b: Invalid library item ${req.params.id}: not a book`)
|
||||||
return res.status(400).send('Invalid library item: not a book')
|
return res.status(400).send('Invalid library item: not a book')
|
||||||
}
|
}
|
||||||
|
|
||||||
if (req.libraryItem.media.tracks.length <= 0) {
|
if (!req.libraryItem.hasAudioTracks) {
|
||||||
Logger.error(`[MiscController] encodeM4b: Invalid audiobook ${req.params.id}: no audio tracks`)
|
Logger.error(`[MiscController] encodeM4b: Invalid audiobook ${req.params.id}: no audio tracks`)
|
||||||
return res.status(400).send('Invalid audiobook: no audio tracks')
|
return res.status(400).send('Invalid audiobook: no audio tracks')
|
||||||
}
|
}
|
||||||
@ -72,11 +77,11 @@ class ToolsController {
|
|||||||
*
|
*
|
||||||
* @this import('../routers/ApiRouter')
|
* @this import('../routers/ApiRouter')
|
||||||
*
|
*
|
||||||
* @param {RequestWithUser} req
|
* @param {RequestWithLibraryItem} req
|
||||||
* @param {Response} res
|
* @param {Response} res
|
||||||
*/
|
*/
|
||||||
async embedAudioFileMetadata(req, res) {
|
async embedAudioFileMetadata(req, res) {
|
||||||
if (req.libraryItem.isMissing || !req.libraryItem.hasAudioFiles || !req.libraryItem.isBook) {
|
if (req.libraryItem.isMissing || !req.libraryItem.hasAudioTracks || !req.libraryItem.isBook) {
|
||||||
Logger.error(`[ToolsController] Invalid library item`)
|
Logger.error(`[ToolsController] Invalid library item`)
|
||||||
return res.sendStatus(400)
|
return res.sendStatus(400)
|
||||||
}
|
}
|
||||||
@ -111,7 +116,7 @@ class ToolsController {
|
|||||||
|
|
||||||
const libraryItems = []
|
const libraryItems = []
|
||||||
for (const libraryItemId of libraryItemIds) {
|
for (const libraryItemId of libraryItemIds) {
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(libraryItemId)
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
Logger.error(`[ToolsController] Batch embed metadata library item (${libraryItemId}) not found`)
|
Logger.error(`[ToolsController] Batch embed metadata library item (${libraryItemId}) not found`)
|
||||||
return res.sendStatus(404)
|
return res.sendStatus(404)
|
||||||
@ -123,7 +128,7 @@ class ToolsController {
|
|||||||
return res.sendStatus(403)
|
return res.sendStatus(403)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (libraryItem.isMissing || !libraryItem.hasAudioFiles || !libraryItem.isBook) {
|
if (libraryItem.isMissing || !libraryItem.hasAudioTracks || !libraryItem.isBook) {
|
||||||
Logger.error(`[ToolsController] Batch embed invalid library item (${libraryItemId})`)
|
Logger.error(`[ToolsController] Batch embed invalid library item (${libraryItemId})`)
|
||||||
return res.sendStatus(400)
|
return res.sendStatus(400)
|
||||||
}
|
}
|
||||||
@ -157,7 +162,7 @@ class ToolsController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (req.params.id) {
|
if (req.params.id) {
|
||||||
const item = await Database.libraryItemModel.getOldById(req.params.id)
|
const item = await Database.libraryItemModel.getExpandedById(req.params.id)
|
||||||
if (!item?.media) return res.sendStatus(404)
|
if (!item?.media) return res.sendStatus(404)
|
||||||
|
|
||||||
// Check user can access this library item
|
// Check user can access this library item
|
||||||
|
@ -361,7 +361,7 @@ class BookFinder {
|
|||||||
/**
|
/**
|
||||||
* Search for books including fuzzy searches
|
* Search for books including fuzzy searches
|
||||||
*
|
*
|
||||||
* @param {Object} libraryItem
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
* @param {string} provider
|
* @param {string} provider
|
||||||
* @param {string} title
|
* @param {string} title
|
||||||
* @param {string} author
|
* @param {string} author
|
||||||
|
@ -51,7 +51,7 @@ class AbMergeManager {
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {string} userId
|
* @param {string} userId
|
||||||
* @param {import('../objects/LibraryItem')} libraryItem
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
* @param {AbMergeEncodeOptions} [options={}]
|
* @param {AbMergeEncodeOptions} [options={}]
|
||||||
*/
|
*/
|
||||||
async startAudiobookMerge(userId, libraryItem, options = {}) {
|
async startAudiobookMerge(userId, libraryItem, options = {}) {
|
||||||
@ -67,7 +67,7 @@ class AbMergeManager {
|
|||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItemDir,
|
libraryItemDir,
|
||||||
userId,
|
userId,
|
||||||
originalTrackPaths: libraryItem.media.tracks.map((t) => t.metadata.path),
|
originalTrackPaths: libraryItem.media.includedAudioFiles.map((t) => t.metadata.path),
|
||||||
inos: libraryItem.media.includedAudioFiles.map((f) => f.ino),
|
inos: libraryItem.media.includedAudioFiles.map((f) => f.ino),
|
||||||
tempFilepath,
|
tempFilepath,
|
||||||
targetFilename,
|
targetFilename,
|
||||||
@ -86,9 +86,9 @@ class AbMergeManager {
|
|||||||
key: 'MessageTaskEncodingM4b'
|
key: 'MessageTaskEncodingM4b'
|
||||||
}
|
}
|
||||||
const taskDescriptionString = {
|
const taskDescriptionString = {
|
||||||
text: `Encoding audiobook "${libraryItem.media.metadata.title}" into a single m4b file.`,
|
text: `Encoding audiobook "${libraryItem.media.title}" into a single m4b file.`,
|
||||||
key: 'MessageTaskEncodingM4bDescription',
|
key: 'MessageTaskEncodingM4bDescription',
|
||||||
subs: [libraryItem.media.metadata.title]
|
subs: [libraryItem.media.title]
|
||||||
}
|
}
|
||||||
task.setData('encode-m4b', taskTitleString, taskDescriptionString, false, taskData)
|
task.setData('encode-m4b', taskTitleString, taskDescriptionString, false, taskData)
|
||||||
TaskManager.addTask(task)
|
TaskManager.addTask(task)
|
||||||
@ -103,7 +103,7 @@ class AbMergeManager {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {import('../objects/LibraryItem')} libraryItem
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
* @param {Task} task
|
* @param {Task} task
|
||||||
* @param {AbMergeEncodeOptions} encodingOptions
|
* @param {AbMergeEncodeOptions} encodingOptions
|
||||||
*/
|
*/
|
||||||
@ -141,7 +141,7 @@ class AbMergeManager {
|
|||||||
const embedFraction = 1 - encodeFraction
|
const embedFraction = 1 - encodeFraction
|
||||||
try {
|
try {
|
||||||
const trackProgressMonitor = new TrackProgressMonitor(
|
const trackProgressMonitor = new TrackProgressMonitor(
|
||||||
libraryItem.media.tracks.map((t) => t.duration),
|
libraryItem.media.includedAudioFiles.map((t) => t.duration),
|
||||||
(trackIndex) => SocketAuthority.adminEmitter('track_started', { libraryItemId: libraryItem.id, ino: task.data.inos[trackIndex] }),
|
(trackIndex) => SocketAuthority.adminEmitter('track_started', { libraryItemId: libraryItem.id, ino: task.data.inos[trackIndex] }),
|
||||||
(trackIndex, progressInTrack, taskProgress) => {
|
(trackIndex, progressInTrack, taskProgress) => {
|
||||||
SocketAuthority.adminEmitter('track_progress', { libraryItemId: libraryItem.id, ino: task.data.inos[trackIndex], progress: progressInTrack })
|
SocketAuthority.adminEmitter('track_progress', { libraryItemId: libraryItem.id, ino: task.data.inos[trackIndex], progress: progressInTrack })
|
||||||
@ -150,7 +150,7 @@ class AbMergeManager {
|
|||||||
(trackIndex) => SocketAuthority.adminEmitter('track_finished', { libraryItemId: libraryItem.id, ino: task.data.inos[trackIndex] })
|
(trackIndex) => SocketAuthority.adminEmitter('track_finished', { libraryItemId: libraryItem.id, ino: task.data.inos[trackIndex] })
|
||||||
)
|
)
|
||||||
task.data.ffmpeg = new Ffmpeg()
|
task.data.ffmpeg = new Ffmpeg()
|
||||||
await ffmpegHelpers.mergeAudioFiles(libraryItem.media.tracks, task.data.duration, task.data.itemCachePath, task.data.tempFilepath, encodingOptions, (progress) => trackProgressMonitor.update(progress), task.data.ffmpeg)
|
await ffmpegHelpers.mergeAudioFiles(libraryItem.media.includedAudioFiles, task.data.duration, task.data.itemCachePath, task.data.tempFilepath, encodingOptions, (progress) => trackProgressMonitor.update(progress), task.data.ffmpeg)
|
||||||
delete task.data.ffmpeg
|
delete task.data.ffmpeg
|
||||||
trackProgressMonitor.finish()
|
trackProgressMonitor.finish()
|
||||||
} catch (error) {
|
} catch (error) {
|
||||||
|
@ -42,6 +42,8 @@ class ApiCacheManager {
|
|||||||
Logger.debug(`[ApiCacheManager] Skipping cache for random sort`)
|
Logger.debug(`[ApiCacheManager] Skipping cache for random sort`)
|
||||||
return next()
|
return next()
|
||||||
}
|
}
|
||||||
|
// Force URL to be lower case for matching against routes
|
||||||
|
req.url = req.url.toLowerCase()
|
||||||
const key = { user: req.user.username, url: req.url }
|
const key = { user: req.user.username, url: req.url }
|
||||||
const stringifiedKey = JSON.stringify(key)
|
const stringifiedKey = JSON.stringify(key)
|
||||||
Logger.debug(`[ApiCacheManager] count: ${this.cache.size} size: ${this.cache.calculatedSize}`)
|
Logger.debug(`[ApiCacheManager] count: ${this.cache.size} size: ${this.cache.calculatedSize}`)
|
||||||
|
@ -34,6 +34,11 @@ class AudioMetadataMangaer {
|
|||||||
return this.tasksQueued.some((t) => t.data.libraryItemId === libraryItemId) || this.tasksRunning.some((t) => t.data.libraryItemId === libraryItemId)
|
return this.tasksQueued.some((t) => t.data.libraryItemId === libraryItemId) || this.tasksRunning.some((t) => t.data.libraryItemId === libraryItemId)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @returns
|
||||||
|
*/
|
||||||
getMetadataObjectForApi(libraryItem) {
|
getMetadataObjectForApi(libraryItem) {
|
||||||
return ffmpegHelpers.getFFMetadataObject(libraryItem, libraryItem.media.includedAudioFiles.length)
|
return ffmpegHelpers.getFFMetadataObject(libraryItem, libraryItem.media.includedAudioFiles.length)
|
||||||
}
|
}
|
||||||
@ -41,8 +46,8 @@ class AudioMetadataMangaer {
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {string} userId
|
* @param {string} userId
|
||||||
* @param {*} libraryItems
|
* @param {import('../models/LibraryItem')[]} libraryItems
|
||||||
* @param {*} options
|
* @param {UpdateMetadataOptions} options
|
||||||
*/
|
*/
|
||||||
handleBatchEmbed(userId, libraryItems, options = {}) {
|
handleBatchEmbed(userId, libraryItems, options = {}) {
|
||||||
libraryItems.forEach((li) => {
|
libraryItems.forEach((li) => {
|
||||||
@ -53,7 +58,7 @@ class AudioMetadataMangaer {
|
|||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {string} userId
|
* @param {string} userId
|
||||||
* @param {import('../objects/LibraryItem')} libraryItem
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
* @param {UpdateMetadataOptions} [options={}]
|
* @param {UpdateMetadataOptions} [options={}]
|
||||||
*/
|
*/
|
||||||
async updateMetadataForItem(userId, libraryItem, options = {}) {
|
async updateMetadataForItem(userId, libraryItem, options = {}) {
|
||||||
@ -103,14 +108,14 @@ class AudioMetadataMangaer {
|
|||||||
key: 'MessageTaskEmbeddingMetadata'
|
key: 'MessageTaskEmbeddingMetadata'
|
||||||
}
|
}
|
||||||
const taskDescriptionString = {
|
const taskDescriptionString = {
|
||||||
text: `Embedding metadata in audiobook "${libraryItem.media.metadata.title}".`,
|
text: `Embedding metadata in audiobook "${libraryItem.media.title}".`,
|
||||||
key: 'MessageTaskEmbeddingMetadataDescription',
|
key: 'MessageTaskEmbeddingMetadataDescription',
|
||||||
subs: [libraryItem.media.metadata.title]
|
subs: [libraryItem.media.title]
|
||||||
}
|
}
|
||||||
task.setData('embed-metadata', taskTitleString, taskDescriptionString, false, taskData)
|
task.setData('embed-metadata', taskTitleString, taskDescriptionString, false, taskData)
|
||||||
|
|
||||||
if (this.tasksRunning.length >= this.MAX_CONCURRENT_TASKS) {
|
if (this.tasksRunning.length >= this.MAX_CONCURRENT_TASKS) {
|
||||||
Logger.info(`[AudioMetadataManager] Queueing embed metadata for audiobook "${libraryItem.media.metadata.title}"`)
|
Logger.info(`[AudioMetadataManager] Queueing embed metadata for audiobook "${libraryItem.media.title}"`)
|
||||||
SocketAuthority.adminEmitter('metadata_embed_queue_update', {
|
SocketAuthority.adminEmitter('metadata_embed_queue_update', {
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
queued: true
|
queued: true
|
||||||
|
@ -79,6 +79,12 @@ class CoverManager {
|
|||||||
return imgType
|
return imgType
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @param {*} coverFile - file object from req.files
|
||||||
|
* @returns {Promise<{error:string}|{cover:string}>}
|
||||||
|
*/
|
||||||
async uploadCover(libraryItem, coverFile) {
|
async uploadCover(libraryItem, coverFile) {
|
||||||
const extname = Path.extname(coverFile.name.toLowerCase())
|
const extname = Path.extname(coverFile.name.toLowerCase())
|
||||||
if (!extname || !globals.SupportedImageTypes.includes(extname.slice(1))) {
|
if (!extname || !globals.SupportedImageTypes.includes(extname.slice(1))) {
|
||||||
@ -110,62 +116,19 @@ class CoverManager {
|
|||||||
await this.removeOldCovers(coverDirPath, extname)
|
await this.removeOldCovers(coverDirPath, extname)
|
||||||
await CacheManager.purgeCoverCache(libraryItem.id)
|
await CacheManager.purgeCoverCache(libraryItem.id)
|
||||||
|
|
||||||
Logger.info(`[CoverManager] Uploaded libraryItem cover "${coverFullPath}" for "${libraryItem.media.metadata.title}"`)
|
Logger.info(`[CoverManager] Uploaded libraryItem cover "${coverFullPath}" for "${libraryItem.media.title}"`)
|
||||||
|
|
||||||
libraryItem.updateMediaCover(coverFullPath)
|
|
||||||
return {
|
return {
|
||||||
cover: coverFullPath
|
cover: coverFullPath
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
async downloadCoverFromUrl(libraryItem, url, forceLibraryItemFolder = false) {
|
/**
|
||||||
try {
|
*
|
||||||
// Force save cover with library item is used for adding new podcasts
|
* @param {string} coverPath
|
||||||
var coverDirPath = forceLibraryItemFolder ? libraryItem.path : this.getCoverDirectory(libraryItem)
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
await fs.ensureDir(coverDirPath)
|
* @returns {Promise<{error:string}|{cover:string,updated:boolean}>}
|
||||||
|
*/
|
||||||
var temppath = Path.posix.join(coverDirPath, 'cover')
|
|
||||||
|
|
||||||
let errorMsg = ''
|
|
||||||
let success = await downloadImageFile(url, temppath)
|
|
||||||
.then(() => true)
|
|
||||||
.catch((err) => {
|
|
||||||
errorMsg = err.message || 'Unknown error'
|
|
||||||
Logger.error(`[CoverManager] Download image file failed for "${url}"`, errorMsg)
|
|
||||||
return false
|
|
||||||
})
|
|
||||||
if (!success) {
|
|
||||||
return {
|
|
||||||
error: 'Failed to download image from url: ' + errorMsg
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
var imgtype = await this.checkFileIsValidImage(temppath, true)
|
|
||||||
|
|
||||||
if (imgtype.error) {
|
|
||||||
return imgtype
|
|
||||||
}
|
|
||||||
|
|
||||||
var coverFilename = `cover.${imgtype.ext}`
|
|
||||||
var coverFullPath = Path.posix.join(coverDirPath, coverFilename)
|
|
||||||
await fs.rename(temppath, coverFullPath)
|
|
||||||
|
|
||||||
await this.removeOldCovers(coverDirPath, '.' + imgtype.ext)
|
|
||||||
await CacheManager.purgeCoverCache(libraryItem.id)
|
|
||||||
|
|
||||||
Logger.info(`[CoverManager] Downloaded libraryItem cover "${coverFullPath}" from url "${url}" for "${libraryItem.media.metadata.title}"`)
|
|
||||||
libraryItem.updateMediaCover(coverFullPath)
|
|
||||||
return {
|
|
||||||
cover: coverFullPath
|
|
||||||
}
|
|
||||||
} catch (error) {
|
|
||||||
Logger.error(`[CoverManager] Fetch cover image from url "${url}" failed`, error)
|
|
||||||
return {
|
|
||||||
error: 'Failed to fetch image from url'
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
async validateCoverPath(coverPath, libraryItem) {
|
async validateCoverPath(coverPath, libraryItem) {
|
||||||
// Invalid cover path
|
// Invalid cover path
|
||||||
if (!coverPath || coverPath.startsWith('http:') || coverPath.startsWith('https:')) {
|
if (!coverPath || coverPath.startsWith('http:') || coverPath.startsWith('https:')) {
|
||||||
@ -235,7 +198,6 @@ class CoverManager {
|
|||||||
|
|
||||||
await CacheManager.purgeCoverCache(libraryItem.id)
|
await CacheManager.purgeCoverCache(libraryItem.id)
|
||||||
|
|
||||||
libraryItem.updateMediaCover(coverPath)
|
|
||||||
return {
|
return {
|
||||||
cover: coverPath,
|
cover: coverPath,
|
||||||
updated: true
|
updated: true
|
||||||
@ -321,13 +283,14 @@ class CoverManager {
|
|||||||
*
|
*
|
||||||
* @param {string} url
|
* @param {string} url
|
||||||
* @param {string} libraryItemId
|
* @param {string} libraryItemId
|
||||||
* @param {string} [libraryItemPath] null if library item isFile or is from adding new podcast
|
* @param {string} [libraryItemPath] - null if library item isFile
|
||||||
|
* @param {boolean} [forceLibraryItemFolder=false] - force save cover with library item (used for adding new podcasts)
|
||||||
* @returns {Promise<{error:string}|{cover:string}>}
|
* @returns {Promise<{error:string}|{cover:string}>}
|
||||||
*/
|
*/
|
||||||
async downloadCoverFromUrlNew(url, libraryItemId, libraryItemPath) {
|
async downloadCoverFromUrlNew(url, libraryItemId, libraryItemPath, forceLibraryItemFolder = false) {
|
||||||
try {
|
try {
|
||||||
let coverDirPath = null
|
let coverDirPath = null
|
||||||
if (global.ServerSettings.storeCoverWithItem && libraryItemPath) {
|
if ((global.ServerSettings.storeCoverWithItem || forceLibraryItemFolder) && libraryItemPath) {
|
||||||
coverDirPath = libraryItemPath
|
coverDirPath = libraryItemPath
|
||||||
} else {
|
} else {
|
||||||
coverDirPath = Path.posix.join(global.MetadataPath, 'items', libraryItemId)
|
coverDirPath = Path.posix.join(global.MetadataPath, 'items', libraryItemId)
|
||||||
|
@ -181,7 +181,7 @@ class CronManager {
|
|||||||
// Get podcast library items to check
|
// Get podcast library items to check
|
||||||
const libraryItems = []
|
const libraryItems = []
|
||||||
for (const libraryItemId of libraryItemIds) {
|
for (const libraryItemId of libraryItemIds) {
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(libraryItemId)
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
Logger.error(`[CronManager] Library item ${libraryItemId} not found for episode check cron ${expression}`)
|
Logger.error(`[CronManager] Library item ${libraryItemId} not found for episode check cron ${expression}`)
|
||||||
podcastCron.libraryItemIds = podcastCron.libraryItemIds.filter((lid) => lid !== libraryItemId) // Filter it out
|
podcastCron.libraryItemIds = podcastCron.libraryItemIds.filter((lid) => lid !== libraryItemId) // Filter it out
|
||||||
@ -215,6 +215,10 @@ class CronManager {
|
|||||||
this.podcastCrons = this.podcastCrons.filter((pc) => pc.expression !== podcastCron.expression)
|
this.podcastCrons = this.podcastCrons.filter((pc) => pc.expression !== podcastCron.expression)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
*/
|
||||||
checkUpdatePodcastCron(libraryItem) {
|
checkUpdatePodcastCron(libraryItem) {
|
||||||
// Remove from old cron by library item id
|
// Remove from old cron by library item id
|
||||||
const existingCron = this.podcastCrons.find((pc) => pc.libraryItemIds.includes(libraryItem.id))
|
const existingCron = this.podcastCrons.find((pc) => pc.libraryItemIds.includes(libraryItem.id))
|
||||||
@ -230,7 +234,10 @@ class CronManager {
|
|||||||
const cronMatchingExpression = this.podcastCrons.find((pc) => pc.expression === libraryItem.media.autoDownloadSchedule)
|
const cronMatchingExpression = this.podcastCrons.find((pc) => pc.expression === libraryItem.media.autoDownloadSchedule)
|
||||||
if (cronMatchingExpression) {
|
if (cronMatchingExpression) {
|
||||||
cronMatchingExpression.libraryItemIds.push(libraryItem.id)
|
cronMatchingExpression.libraryItemIds.push(libraryItem.id)
|
||||||
Logger.info(`[CronManager] Added podcast "${libraryItem.media.metadata.title}" to auto dl episode cron "${cronMatchingExpression.expression}"`)
|
|
||||||
|
// TODO: Update after old model removed
|
||||||
|
const podcastTitle = libraryItem.media.title || libraryItem.media.metadata?.title
|
||||||
|
Logger.info(`[CronManager] Added podcast "${podcastTitle}" to auto dl episode cron "${cronMatchingExpression.expression}"`)
|
||||||
} else {
|
} else {
|
||||||
this.startPodcastCron(libraryItem.media.autoDownloadSchedule, [libraryItem.id])
|
this.startPodcastCron(libraryItem.media.autoDownloadSchedule, [libraryItem.id])
|
||||||
}
|
}
|
||||||
|
@ -14,6 +14,11 @@ class NotificationManager {
|
|||||||
return notificationData
|
return notificationData
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @param {import('../models/PodcastEpisode')} episode
|
||||||
|
*/
|
||||||
async onPodcastEpisodeDownloaded(libraryItem, episode) {
|
async onPodcastEpisodeDownloaded(libraryItem, episode) {
|
||||||
if (!Database.notificationSettings.isUseable) return
|
if (!Database.notificationSettings.isUseable) return
|
||||||
|
|
||||||
@ -22,17 +27,17 @@ class NotificationManager {
|
|||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
Logger.debug(`[NotificationManager] onPodcastEpisodeDownloaded: Episode "${episode.title}" for podcast ${libraryItem.media.metadata.title}`)
|
Logger.debug(`[NotificationManager] onPodcastEpisodeDownloaded: Episode "${episode.title}" for podcast ${libraryItem.media.title}`)
|
||||||
const library = await Database.libraryModel.findByPk(libraryItem.libraryId)
|
const library = await Database.libraryModel.findByPk(libraryItem.libraryId)
|
||||||
const eventData = {
|
const eventData = {
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryId: libraryItem.libraryId,
|
libraryId: libraryItem.libraryId,
|
||||||
libraryName: library?.name || 'Unknown',
|
libraryName: library?.name || 'Unknown',
|
||||||
mediaTags: (libraryItem.media.tags || []).join(', '),
|
mediaTags: (libraryItem.media.tags || []).join(', '),
|
||||||
podcastTitle: libraryItem.media.metadata.title,
|
podcastTitle: libraryItem.media.title,
|
||||||
podcastAuthor: libraryItem.media.metadata.author || '',
|
podcastAuthor: libraryItem.media.author || '',
|
||||||
podcastDescription: libraryItem.media.metadata.description || '',
|
podcastDescription: libraryItem.media.description || '',
|
||||||
podcastGenres: (libraryItem.media.metadata.genres || []).join(', '),
|
podcastGenres: (libraryItem.media.genres || []).join(', '),
|
||||||
episodeId: episode.id,
|
episodeId: episode.id,
|
||||||
episodeTitle: episode.title,
|
episodeTitle: episode.title,
|
||||||
episodeSubtitle: episode.subtitle || '',
|
episodeSubtitle: episode.subtitle || '',
|
||||||
|
@ -39,7 +39,7 @@ class PlaybackSessionManager {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {import('../controllers/SessionController').RequestWithUser} req
|
* @param {import('../controllers/LibraryItemController').LibraryItemControllerRequest} req
|
||||||
* @param {Object} [clientDeviceInfo]
|
* @param {Object} [clientDeviceInfo]
|
||||||
* @returns {Promise<DeviceInfo>}
|
* @returns {Promise<DeviceInfo>}
|
||||||
*/
|
*/
|
||||||
@ -67,7 +67,7 @@ class PlaybackSessionManager {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {import('../controllers/SessionController').RequestWithUser} req
|
* @param {import('../controllers/LibraryItemController').LibraryItemControllerRequest} req
|
||||||
* @param {import('express').Response} res
|
* @param {import('express').Response} res
|
||||||
* @param {string} [episodeId]
|
* @param {string} [episodeId]
|
||||||
*/
|
*/
|
||||||
@ -120,8 +120,8 @@ class PlaybackSessionManager {
|
|||||||
*/
|
*/
|
||||||
async syncLocalSession(user, sessionJson, deviceInfo) {
|
async syncLocalSession(user, sessionJson, deviceInfo) {
|
||||||
// TODO: Combine libraryItem query with library query
|
// TODO: Combine libraryItem query with library query
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(sessionJson.libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(sessionJson.libraryItemId)
|
||||||
const episode = sessionJson.episodeId && libraryItem && libraryItem.isPodcast ? libraryItem.media.getEpisode(sessionJson.episodeId) : null
|
const episode = sessionJson.episodeId && libraryItem && libraryItem.isPodcast ? libraryItem.media.podcastEpisodes.find((pe) => pe.id === sessionJson.episodeId) : null
|
||||||
if (!libraryItem || (libraryItem.isPodcast && !episode)) {
|
if (!libraryItem || (libraryItem.isPodcast && !episode)) {
|
||||||
Logger.error(`[PlaybackSessionManager] syncLocalSession: Media item not found for session "${sessionJson.displayTitle}" (${sessionJson.id})`)
|
Logger.error(`[PlaybackSessionManager] syncLocalSession: Media item not found for session "${sessionJson.displayTitle}" (${sessionJson.id})`)
|
||||||
return {
|
return {
|
||||||
@ -175,7 +175,8 @@ class PlaybackSessionManager {
|
|||||||
// New session from local
|
// New session from local
|
||||||
session = new PlaybackSession(sessionJson)
|
session = new PlaybackSession(sessionJson)
|
||||||
session.deviceInfo = deviceInfo
|
session.deviceInfo = deviceInfo
|
||||||
session.setDuration(libraryItem, sessionJson.episodeId)
|
session.duration = libraryItem.media.getPlaybackDuration(sessionJson.episodeId)
|
||||||
|
|
||||||
Logger.debug(`[PlaybackSessionManager] Inserting new session for "${session.displayTitle}" (${session.id})`)
|
Logger.debug(`[PlaybackSessionManager] Inserting new session for "${session.displayTitle}" (${session.id})`)
|
||||||
await Database.createPlaybackSession(session)
|
await Database.createPlaybackSession(session)
|
||||||
} else {
|
} else {
|
||||||
@ -279,7 +280,7 @@ class PlaybackSessionManager {
|
|||||||
*
|
*
|
||||||
* @param {import('../models/User')} user
|
* @param {import('../models/User')} user
|
||||||
* @param {DeviceInfo} deviceInfo
|
* @param {DeviceInfo} deviceInfo
|
||||||
* @param {import('../objects/LibraryItem')} libraryItem
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
* @param {string|null} episodeId
|
* @param {string|null} episodeId
|
||||||
* @param {{forceDirectPlay?:boolean, forceTranscode?:boolean, mediaPlayer:string, supportedMimeTypes?:string[]}} options
|
* @param {{forceDirectPlay?:boolean, forceTranscode?:boolean, mediaPlayer:string, supportedMimeTypes?:string[]}} options
|
||||||
* @returns {Promise<PlaybackSession>}
|
* @returns {Promise<PlaybackSession>}
|
||||||
@ -292,7 +293,7 @@ class PlaybackSessionManager {
|
|||||||
await this.closeSession(user, session, null)
|
await this.closeSession(user, session, null)
|
||||||
}
|
}
|
||||||
|
|
||||||
const shouldDirectPlay = options.forceDirectPlay || (!options.forceTranscode && libraryItem.media.checkCanDirectPlay(options, episodeId))
|
const shouldDirectPlay = options.forceDirectPlay || (!options.forceTranscode && libraryItem.media.checkCanDirectPlay(options.supportedMimeTypes, episodeId))
|
||||||
const mediaPlayer = options.mediaPlayer || 'unknown'
|
const mediaPlayer = options.mediaPlayer || 'unknown'
|
||||||
|
|
||||||
const mediaItemId = episodeId || libraryItem.media.id
|
const mediaItemId = episodeId || libraryItem.media.id
|
||||||
@ -300,7 +301,7 @@ class PlaybackSessionManager {
|
|||||||
let userStartTime = 0
|
let userStartTime = 0
|
||||||
if (userProgress) {
|
if (userProgress) {
|
||||||
if (userProgress.isFinished) {
|
if (userProgress.isFinished) {
|
||||||
Logger.info(`[PlaybackSessionManager] Starting session for user "${user.username}" and resetting progress for finished item "${libraryItem.media.metadata.title}"`)
|
Logger.info(`[PlaybackSessionManager] Starting session for user "${user.username}" and resetting progress for finished item "${libraryItem.media.title}"`)
|
||||||
// Keep userStartTime as 0 so the client restarts the media
|
// Keep userStartTime as 0 so the client restarts the media
|
||||||
} else {
|
} else {
|
||||||
userStartTime = Number.parseFloat(userProgress.currentTime) || 0
|
userStartTime = Number.parseFloat(userProgress.currentTime) || 0
|
||||||
@ -312,7 +313,7 @@ class PlaybackSessionManager {
|
|||||||
let audioTracks = []
|
let audioTracks = []
|
||||||
if (shouldDirectPlay) {
|
if (shouldDirectPlay) {
|
||||||
Logger.debug(`[PlaybackSessionManager] "${user.username}" starting direct play session for item "${libraryItem.id}" with id ${newPlaybackSession.id} (Device: ${newPlaybackSession.deviceDescription})`)
|
Logger.debug(`[PlaybackSessionManager] "${user.username}" starting direct play session for item "${libraryItem.id}" with id ${newPlaybackSession.id} (Device: ${newPlaybackSession.deviceDescription})`)
|
||||||
audioTracks = libraryItem.getDirectPlayTracklist(episodeId)
|
audioTracks = libraryItem.getTrackList(episodeId)
|
||||||
newPlaybackSession.playMethod = PlayMethod.DIRECTPLAY
|
newPlaybackSession.playMethod = PlayMethod.DIRECTPLAY
|
||||||
} else {
|
} else {
|
||||||
Logger.debug(`[PlaybackSessionManager] "${user.username}" starting stream session for item "${libraryItem.id}" (Device: ${newPlaybackSession.deviceDescription})`)
|
Logger.debug(`[PlaybackSessionManager] "${user.username}" starting stream session for item "${libraryItem.id}" (Device: ${newPlaybackSession.deviceDescription})`)
|
||||||
@ -342,20 +343,20 @@ class PlaybackSessionManager {
|
|||||||
* @param {import('../models/User')} user
|
* @param {import('../models/User')} user
|
||||||
* @param {*} session
|
* @param {*} session
|
||||||
* @param {*} syncData
|
* @param {*} syncData
|
||||||
* @returns
|
* @returns {Promise<boolean>}
|
||||||
*/
|
*/
|
||||||
async syncSession(user, session, syncData) {
|
async syncSession(user, session, syncData) {
|
||||||
// TODO: Combine libraryItem query with library query
|
// TODO: Combine libraryItem query with library query
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(session.libraryItemId)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(session.libraryItemId)
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
Logger.error(`[PlaybackSessionManager] syncSession Library Item not found "${session.libraryItemId}"`)
|
Logger.error(`[PlaybackSessionManager] syncSession Library Item not found "${session.libraryItemId}"`)
|
||||||
return null
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
const library = await Database.libraryModel.findByPk(libraryItem.libraryId)
|
const library = await Database.libraryModel.findByPk(libraryItem.libraryId)
|
||||||
if (!library) {
|
if (!library) {
|
||||||
Logger.error(`[PlaybackSessionManager] syncSession Library not found "${libraryItem.libraryId}"`)
|
Logger.error(`[PlaybackSessionManager] syncSession Library not found "${libraryItem.libraryId}"`)
|
||||||
return null
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
session.currentTime = syncData.currentTime
|
session.currentTime = syncData.currentTime
|
||||||
@ -381,9 +382,8 @@ class PlaybackSessionManager {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
this.saveSession(session)
|
this.saveSession(session)
|
||||||
return {
|
|
||||||
libraryItem
|
return true
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1,3 +1,4 @@
|
|||||||
|
const Path = require('path')
|
||||||
const Logger = require('../Logger')
|
const Logger = require('../Logger')
|
||||||
const SocketAuthority = require('../SocketAuthority')
|
const SocketAuthority = require('../SocketAuthority')
|
||||||
const Database = require('../Database')
|
const Database = require('../Database')
|
||||||
@ -19,9 +20,7 @@ const NotificationManager = require('../managers/NotificationManager')
|
|||||||
|
|
||||||
const LibraryFile = require('../objects/files/LibraryFile')
|
const LibraryFile = require('../objects/files/LibraryFile')
|
||||||
const PodcastEpisodeDownload = require('../objects/PodcastEpisodeDownload')
|
const PodcastEpisodeDownload = require('../objects/PodcastEpisodeDownload')
|
||||||
const PodcastEpisode = require('../objects/entities/PodcastEpisode')
|
|
||||||
const AudioFile = require('../objects/files/AudioFile')
|
const AudioFile = require('../objects/files/AudioFile')
|
||||||
const LibraryItem = require('../objects/LibraryItem')
|
|
||||||
|
|
||||||
class PodcastManager {
|
class PodcastManager {
|
||||||
constructor() {
|
constructor() {
|
||||||
@ -52,15 +51,16 @@ class PodcastManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @param {import('../utils/podcastUtils').RssPodcastEpisode[]} episodesToDownload
|
||||||
|
* @param {boolean} isAutoDownload - If this download was triggered by auto download
|
||||||
|
*/
|
||||||
async downloadPodcastEpisodes(libraryItem, episodesToDownload, isAutoDownload) {
|
async downloadPodcastEpisodes(libraryItem, episodesToDownload, isAutoDownload) {
|
||||||
let index = Math.max(...libraryItem.media.episodes.filter((ep) => ep.index == null || isNaN(ep.index)).map((ep) => Number(ep.index))) + 1
|
|
||||||
for (const ep of episodesToDownload) {
|
for (const ep of episodesToDownload) {
|
||||||
const newPe = new PodcastEpisode()
|
|
||||||
newPe.setData(ep, index++)
|
|
||||||
newPe.libraryItemId = libraryItem.id
|
|
||||||
newPe.podcastId = libraryItem.media.id
|
|
||||||
const newPeDl = new PodcastEpisodeDownload()
|
const newPeDl = new PodcastEpisodeDownload()
|
||||||
newPeDl.setData(newPe, libraryItem, isAutoDownload, libraryItem.libraryId)
|
newPeDl.setData(ep, libraryItem, isAutoDownload, libraryItem.libraryId)
|
||||||
this.startPodcastEpisodeDownload(newPeDl)
|
this.startPodcastEpisodeDownload(newPeDl)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -86,20 +86,20 @@ class PodcastManager {
|
|||||||
key: 'MessageDownloadingEpisode'
|
key: 'MessageDownloadingEpisode'
|
||||||
}
|
}
|
||||||
const taskDescriptionString = {
|
const taskDescriptionString = {
|
||||||
text: `Downloading episode "${podcastEpisodeDownload.podcastEpisode.title}".`,
|
text: `Downloading episode "${podcastEpisodeDownload.episodeTitle}".`,
|
||||||
key: 'MessageTaskDownloadingEpisodeDescription',
|
key: 'MessageTaskDownloadingEpisodeDescription',
|
||||||
subs: [podcastEpisodeDownload.podcastEpisode.title]
|
subs: [podcastEpisodeDownload.episodeTitle]
|
||||||
}
|
}
|
||||||
const task = TaskManager.createAndAddTask('download-podcast-episode', taskTitleString, taskDescriptionString, false, taskData)
|
const task = TaskManager.createAndAddTask('download-podcast-episode', taskTitleString, taskDescriptionString, false, taskData)
|
||||||
|
|
||||||
SocketAuthority.emitter('episode_download_started', podcastEpisodeDownload.toJSONForClient())
|
SocketAuthority.emitter('episode_download_started', podcastEpisodeDownload.toJSONForClient())
|
||||||
this.currentDownload = podcastEpisodeDownload
|
this.currentDownload = podcastEpisodeDownload
|
||||||
|
|
||||||
// If this file already exists then append the episode id to the filename
|
// If this file already exists then append a uuid to the filename
|
||||||
// e.g. "/tagesschau 20 Uhr.mp3" becomes "/tagesschau 20 Uhr (ep_asdfasdf).mp3"
|
// e.g. "/tagesschau 20 Uhr.mp3" becomes "/tagesschau 20 Uhr (ep_asdfasdf).mp3"
|
||||||
// this handles podcasts where every title is the same (ref https://github.com/advplyr/audiobookshelf/issues/1802)
|
// this handles podcasts where every title is the same (ref https://github.com/advplyr/audiobookshelf/issues/1802)
|
||||||
if (await fs.pathExists(this.currentDownload.targetPath)) {
|
if (await fs.pathExists(this.currentDownload.targetPath)) {
|
||||||
this.currentDownload.appendEpisodeId = true
|
this.currentDownload.appendRandomId = true
|
||||||
}
|
}
|
||||||
|
|
||||||
// Ignores all added files to this dir
|
// Ignores all added files to this dir
|
||||||
@ -115,10 +115,24 @@ class PodcastManager {
|
|||||||
let success = false
|
let success = false
|
||||||
if (this.currentDownload.isMp3) {
|
if (this.currentDownload.isMp3) {
|
||||||
// Download episode and tag it
|
// Download episode and tag it
|
||||||
success = await ffmpegHelpers.downloadPodcastEpisode(this.currentDownload).catch((error) => {
|
const ffmpegDownloadResponse = await ffmpegHelpers.downloadPodcastEpisode(this.currentDownload).catch((error) => {
|
||||||
Logger.error(`[PodcastManager] Podcast Episode download failed`, error)
|
Logger.error(`[PodcastManager] Podcast Episode download failed`, error)
|
||||||
return false
|
|
||||||
})
|
})
|
||||||
|
success = !!ffmpegDownloadResponse?.success
|
||||||
|
|
||||||
|
// If failed due to ffmpeg error, retry without tagging
|
||||||
|
// e.g. RSS feed may have incorrect file extension and file type
|
||||||
|
// See https://github.com/advplyr/audiobookshelf/issues/3837
|
||||||
|
if (!success && ffmpegDownloadResponse?.isFfmpegError) {
|
||||||
|
Logger.info(`[PodcastManager] Retrying episode download without tagging`)
|
||||||
|
// Download episode only
|
||||||
|
success = await downloadFile(this.currentDownload.url, this.currentDownload.targetPath)
|
||||||
|
.then(() => true)
|
||||||
|
.catch((error) => {
|
||||||
|
Logger.error(`[PodcastManager] Podcast Episode download failed`, error)
|
||||||
|
return false
|
||||||
|
})
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
// Download episode only
|
// Download episode only
|
||||||
success = await downloadFile(this.currentDownload.url, this.currentDownload.targetPath)
|
success = await downloadFile(this.currentDownload.url, this.currentDownload.targetPath)
|
||||||
@ -140,7 +154,7 @@ class PodcastManager {
|
|||||||
}
|
}
|
||||||
task.setFailed(taskFailedString)
|
task.setFailed(taskFailedString)
|
||||||
} else {
|
} else {
|
||||||
Logger.info(`[PodcastManager] Successfully downloaded podcast episode "${this.currentDownload.podcastEpisode.title}"`)
|
Logger.info(`[PodcastManager] Successfully downloaded podcast episode "${this.currentDownload.episodeTitle}"`)
|
||||||
this.currentDownload.setFinished(true)
|
this.currentDownload.setFinished(true)
|
||||||
task.setFinished()
|
task.setFinished()
|
||||||
}
|
}
|
||||||
@ -166,47 +180,61 @@ class PodcastManager {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Scans the downloaded audio file, create the podcast episode, remove oldest episode if necessary
|
||||||
|
* @returns {Promise<boolean>} - Returns true if added
|
||||||
|
*/
|
||||||
async scanAddPodcastEpisodeAudioFile() {
|
async scanAddPodcastEpisodeAudioFile() {
|
||||||
const libraryFile = await this.getLibraryFile(this.currentDownload.targetPath, this.currentDownload.targetRelPath)
|
const libraryFile = new LibraryFile()
|
||||||
|
await libraryFile.setDataFromPath(this.currentDownload.targetPath, this.currentDownload.targetRelPath)
|
||||||
|
|
||||||
const audioFile = await this.probeAudioFile(libraryFile)
|
const audioFile = await this.probeAudioFile(libraryFile)
|
||||||
if (!audioFile) {
|
if (!audioFile) {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
const libraryItem = await Database.libraryItemModel.getOldById(this.currentDownload.libraryItem.id)
|
const libraryItem = await Database.libraryItemModel.getExpandedById(this.currentDownload.libraryItem.id)
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
Logger.error(`[PodcastManager] Podcast Episode finished but library item was not found ${this.currentDownload.libraryItem.id}`)
|
Logger.error(`[PodcastManager] Podcast Episode finished but library item was not found ${this.currentDownload.libraryItem.id}`)
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
const podcastEpisode = this.currentDownload.podcastEpisode
|
const podcastEpisode = await Database.podcastEpisodeModel.createFromRssPodcastEpisode(this.currentDownload.rssPodcastEpisode, libraryItem.media.id, audioFile)
|
||||||
podcastEpisode.audioFile = audioFile
|
|
||||||
|
|
||||||
if (audioFile.chapters?.length) {
|
libraryItem.libraryFiles.push(libraryFile.toJSON())
|
||||||
podcastEpisode.chapters = audioFile.chapters.map((ch) => ({ ...ch }))
|
libraryItem.changed('libraryFiles', true)
|
||||||
}
|
|
||||||
|
|
||||||
libraryItem.media.addPodcastEpisode(podcastEpisode)
|
libraryItem.media.podcastEpisodes.push(podcastEpisode)
|
||||||
if (libraryItem.isInvalid) {
|
|
||||||
// First episode added to an empty podcast
|
|
||||||
libraryItem.isInvalid = false
|
|
||||||
}
|
|
||||||
libraryItem.libraryFiles.push(libraryFile)
|
|
||||||
|
|
||||||
if (this.currentDownload.isAutoDownload) {
|
if (this.currentDownload.isAutoDownload) {
|
||||||
// Check setting maxEpisodesToKeep and remove episode if necessary
|
// Check setting maxEpisodesToKeep and remove episode if necessary
|
||||||
if (libraryItem.media.maxEpisodesToKeep && libraryItem.media.episodesWithPubDate.length > libraryItem.media.maxEpisodesToKeep) {
|
const numEpisodesWithPubDate = libraryItem.media.podcastEpisodes.filter((ep) => !!ep.publishedAt).length
|
||||||
Logger.info(`[PodcastManager] # of episodes (${libraryItem.media.episodesWithPubDate.length}) exceeds max episodes to keep (${libraryItem.media.maxEpisodesToKeep})`)
|
if (libraryItem.media.maxEpisodesToKeep && numEpisodesWithPubDate > libraryItem.media.maxEpisodesToKeep) {
|
||||||
await this.removeOldestEpisode(libraryItem, podcastEpisode.id)
|
Logger.info(`[PodcastManager] # of episodes (${numEpisodesWithPubDate}) exceeds max episodes to keep (${libraryItem.media.maxEpisodesToKeep})`)
|
||||||
|
const episodeToRemove = await this.getRemoveOldestEpisode(libraryItem, podcastEpisode.id)
|
||||||
|
if (episodeToRemove) {
|
||||||
|
// Remove episode from playlists
|
||||||
|
await Database.playlistModel.removeMediaItemsFromPlaylists([episodeToRemove.id])
|
||||||
|
// Remove media progress for this episode
|
||||||
|
await Database.mediaProgressModel.destroy({
|
||||||
|
where: {
|
||||||
|
mediaItemId: episodeToRemove.id
|
||||||
|
}
|
||||||
|
})
|
||||||
|
await episodeToRemove.destroy()
|
||||||
|
libraryItem.media.podcastEpisodes = libraryItem.media.podcastEpisodes.filter((ep) => ep.id !== episodeToRemove.id)
|
||||||
|
|
||||||
|
// Remove library file
|
||||||
|
libraryItem.libraryFiles = libraryItem.libraryFiles.filter((lf) => lf.ino !== episodeToRemove.audioFile.ino)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
libraryItem.updatedAt = Date.now()
|
await libraryItem.save()
|
||||||
await Database.updateLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
const podcastEpisodeExpanded = podcastEpisode.toJSONExpanded()
|
const podcastEpisodeExpanded = podcastEpisode.toOldJSONExpanded(libraryItem.id)
|
||||||
podcastEpisodeExpanded.libraryItem = libraryItem.toJSONExpanded()
|
podcastEpisodeExpanded.libraryItem = libraryItem.toOldJSONExpanded()
|
||||||
SocketAuthority.emitter('episode_added', podcastEpisodeExpanded)
|
SocketAuthority.emitter('episode_added', podcastEpisodeExpanded)
|
||||||
|
|
||||||
if (this.currentDownload.isAutoDownload) {
|
if (this.currentDownload.isAutoDownload) {
|
||||||
@ -217,45 +245,53 @@ class PodcastManager {
|
|||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
|
||||||
async removeOldestEpisode(libraryItem, episodeIdJustDownloaded) {
|
/**
|
||||||
var smallestPublishedAt = 0
|
* Find oldest episode publishedAt and delete the audio file
|
||||||
var oldestEpisode = null
|
*
|
||||||
libraryItem.media.episodesWithPubDate
|
* @param {import('../models/LibraryItem').LibraryItemExpanded} libraryItem
|
||||||
.filter((ep) => ep.id !== episodeIdJustDownloaded)
|
* @param {string} episodeIdJustDownloaded
|
||||||
.forEach((ep) => {
|
* @returns {Promise<import('../models/PodcastEpisode')|null>} - Returns the episode to remove
|
||||||
if (!smallestPublishedAt || ep.publishedAt < smallestPublishedAt) {
|
*/
|
||||||
smallestPublishedAt = ep.publishedAt
|
async getRemoveOldestEpisode(libraryItem, episodeIdJustDownloaded) {
|
||||||
oldestEpisode = ep
|
let smallestPublishedAt = 0
|
||||||
}
|
/** @type {import('../models/PodcastEpisode')} */
|
||||||
})
|
let oldestEpisode = null
|
||||||
// TODO: Should we check for open playback sessions for this episode?
|
|
||||||
// TODO: remove all user progress for this episode
|
/** @type {import('../models/PodcastEpisode')[]} */
|
||||||
|
const podcastEpisodes = libraryItem.media.podcastEpisodes
|
||||||
|
|
||||||
|
for (const ep of podcastEpisodes) {
|
||||||
|
if (ep.id === episodeIdJustDownloaded || !ep.publishedAt) continue
|
||||||
|
|
||||||
|
if (!smallestPublishedAt || ep.publishedAt < smallestPublishedAt) {
|
||||||
|
smallestPublishedAt = ep.publishedAt
|
||||||
|
oldestEpisode = ep
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if (oldestEpisode?.audioFile) {
|
if (oldestEpisode?.audioFile) {
|
||||||
Logger.info(`[PodcastManager] Deleting oldest episode "${oldestEpisode.title}"`)
|
Logger.info(`[PodcastManager] Deleting oldest episode "${oldestEpisode.title}"`)
|
||||||
const successfullyDeleted = await removeFile(oldestEpisode.audioFile.metadata.path)
|
const successfullyDeleted = await removeFile(oldestEpisode.audioFile.metadata.path)
|
||||||
if (successfullyDeleted) {
|
if (successfullyDeleted) {
|
||||||
libraryItem.media.removeEpisode(oldestEpisode.id)
|
return oldestEpisode
|
||||||
libraryItem.removeLibraryFile(oldestEpisode.audioFile.ino)
|
|
||||||
return true
|
|
||||||
} else {
|
} else {
|
||||||
Logger.warn(`[PodcastManager] Failed to remove oldest episode "${oldestEpisode.title}"`)
|
Logger.warn(`[PodcastManager] Failed to remove oldest episode "${oldestEpisode.title}"`)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return false
|
return null
|
||||||
}
|
|
||||||
|
|
||||||
async getLibraryFile(path, relPath) {
|
|
||||||
var newLibFile = new LibraryFile()
|
|
||||||
await newLibFile.setDataFromPath(path, relPath)
|
|
||||||
return newLibFile
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {LibraryFile} libraryFile
|
||||||
|
* @returns {Promise<AudioFile|null>}
|
||||||
|
*/
|
||||||
async probeAudioFile(libraryFile) {
|
async probeAudioFile(libraryFile) {
|
||||||
const path = libraryFile.metadata.path
|
const path = libraryFile.metadata.path
|
||||||
const mediaProbeData = await prober.probe(path)
|
const mediaProbeData = await prober.probe(path)
|
||||||
if (mediaProbeData.error) {
|
if (mediaProbeData.error) {
|
||||||
Logger.error(`[PodcastManager] Podcast Episode downloaded but failed to probe "${path}"`, mediaProbeData.error)
|
Logger.error(`[PodcastManager] Podcast Episode downloaded but failed to probe "${path}"`, mediaProbeData.error)
|
||||||
return false
|
return null
|
||||||
}
|
}
|
||||||
const newAudioFile = new AudioFile()
|
const newAudioFile = new AudioFile()
|
||||||
newAudioFile.setDataFromProbe(libraryFile, mediaProbeData)
|
newAudioFile.setDataFromProbe(libraryFile, mediaProbeData)
|
||||||
@ -263,18 +299,23 @@ class PodcastManager {
|
|||||||
return newAudioFile
|
return newAudioFile
|
||||||
}
|
}
|
||||||
|
|
||||||
// Returns false if auto download episodes was disabled (disabled if reaches max failed checks)
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @returns {Promise<boolean>} - Returns false if auto download episodes was disabled (disabled if reaches max failed checks)
|
||||||
|
*/
|
||||||
async runEpisodeCheck(libraryItem) {
|
async runEpisodeCheck(libraryItem) {
|
||||||
const lastEpisodeCheckDate = new Date(libraryItem.media.lastEpisodeCheck || 0)
|
const lastEpisodeCheck = libraryItem.media.lastEpisodeCheck?.valueOf() || 0
|
||||||
const latestEpisodePublishedAt = libraryItem.media.latestEpisodePublished
|
const latestEpisodePublishedAt = libraryItem.media.getLatestEpisodePublishedAt()
|
||||||
Logger.info(`[PodcastManager] runEpisodeCheck: "${libraryItem.media.metadata.title}" | Last check: ${lastEpisodeCheckDate} | ${latestEpisodePublishedAt ? `Latest episode pubDate: ${new Date(latestEpisodePublishedAt)}` : 'No latest episode'}`)
|
|
||||||
|
|
||||||
// Use latest episode pubDate if exists OR fallback to using lastEpisodeCheckDate
|
Logger.info(`[PodcastManager] runEpisodeCheck: "${libraryItem.media.title}" | Last check: ${new Date(lastEpisodeCheck)} | ${latestEpisodePublishedAt ? `Latest episode pubDate: ${new Date(latestEpisodePublishedAt)}` : 'No latest episode'}`)
|
||||||
// lastEpisodeCheckDate will be the current time when adding a new podcast
|
|
||||||
const dateToCheckForEpisodesAfter = latestEpisodePublishedAt || lastEpisodeCheckDate
|
|
||||||
Logger.debug(`[PodcastManager] runEpisodeCheck: "${libraryItem.media.metadata.title}" checking for episodes after ${new Date(dateToCheckForEpisodesAfter)}`)
|
|
||||||
|
|
||||||
var newEpisodes = await this.checkPodcastForNewEpisodes(libraryItem, dateToCheckForEpisodesAfter, libraryItem.media.maxNewEpisodesToDownload)
|
// Use latest episode pubDate if exists OR fallback to using lastEpisodeCheck
|
||||||
|
// lastEpisodeCheck will be the current time when adding a new podcast
|
||||||
|
const dateToCheckForEpisodesAfter = latestEpisodePublishedAt || lastEpisodeCheck
|
||||||
|
Logger.debug(`[PodcastManager] runEpisodeCheck: "${libraryItem.media.title}" checking for episodes after ${new Date(dateToCheckForEpisodesAfter)}`)
|
||||||
|
|
||||||
|
const newEpisodes = await this.checkPodcastForNewEpisodes(libraryItem, dateToCheckForEpisodesAfter, libraryItem.media.maxNewEpisodesToDownload)
|
||||||
Logger.debug(`[PodcastManager] runEpisodeCheck: ${newEpisodes?.length || 'N/A'} episodes found`)
|
Logger.debug(`[PodcastManager] runEpisodeCheck: ${newEpisodes?.length || 'N/A'} episodes found`)
|
||||||
|
|
||||||
if (!newEpisodes) {
|
if (!newEpisodes) {
|
||||||
@ -283,37 +324,48 @@ class PodcastManager {
|
|||||||
if (!this.failedCheckMap[libraryItem.id]) this.failedCheckMap[libraryItem.id] = 0
|
if (!this.failedCheckMap[libraryItem.id]) this.failedCheckMap[libraryItem.id] = 0
|
||||||
this.failedCheckMap[libraryItem.id]++
|
this.failedCheckMap[libraryItem.id]++
|
||||||
if (this.failedCheckMap[libraryItem.id] >= this.MaxFailedEpisodeChecks) {
|
if (this.failedCheckMap[libraryItem.id] >= this.MaxFailedEpisodeChecks) {
|
||||||
Logger.error(`[PodcastManager] runEpisodeCheck ${this.failedCheckMap[libraryItem.id]} failed attempts at checking episodes for "${libraryItem.media.metadata.title}" - disabling auto download`)
|
Logger.error(`[PodcastManager] runEpisodeCheck ${this.failedCheckMap[libraryItem.id]} failed attempts at checking episodes for "${libraryItem.media.title}" - disabling auto download`)
|
||||||
libraryItem.media.autoDownloadEpisodes = false
|
libraryItem.media.autoDownloadEpisodes = false
|
||||||
delete this.failedCheckMap[libraryItem.id]
|
delete this.failedCheckMap[libraryItem.id]
|
||||||
} else {
|
} else {
|
||||||
Logger.warn(`[PodcastManager] runEpisodeCheck ${this.failedCheckMap[libraryItem.id]} failed attempts at checking episodes for "${libraryItem.media.metadata.title}"`)
|
Logger.warn(`[PodcastManager] runEpisodeCheck ${this.failedCheckMap[libraryItem.id]} failed attempts at checking episodes for "${libraryItem.media.title}"`)
|
||||||
}
|
}
|
||||||
} else if (newEpisodes.length) {
|
} else if (newEpisodes.length) {
|
||||||
delete this.failedCheckMap[libraryItem.id]
|
delete this.failedCheckMap[libraryItem.id]
|
||||||
Logger.info(`[PodcastManager] Found ${newEpisodes.length} new episodes for podcast "${libraryItem.media.metadata.title}" - starting download`)
|
Logger.info(`[PodcastManager] Found ${newEpisodes.length} new episodes for podcast "${libraryItem.media.title}" - starting download`)
|
||||||
this.downloadPodcastEpisodes(libraryItem, newEpisodes, true)
|
this.downloadPodcastEpisodes(libraryItem, newEpisodes, true)
|
||||||
} else {
|
} else {
|
||||||
delete this.failedCheckMap[libraryItem.id]
|
delete this.failedCheckMap[libraryItem.id]
|
||||||
Logger.debug(`[PodcastManager] No new episodes for "${libraryItem.media.metadata.title}"`)
|
Logger.debug(`[PodcastManager] No new episodes for "${libraryItem.media.title}"`)
|
||||||
}
|
}
|
||||||
|
|
||||||
libraryItem.media.lastEpisodeCheck = Date.now()
|
libraryItem.media.lastEpisodeCheck = new Date()
|
||||||
libraryItem.updatedAt = Date.now()
|
await libraryItem.media.save()
|
||||||
await Database.updateLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
libraryItem.changed('updatedAt', true)
|
||||||
|
await libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
|
|
||||||
return libraryItem.media.autoDownloadEpisodes
|
return libraryItem.media.autoDownloadEpisodes
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} podcastLibraryItem
|
||||||
|
* @param {number} dateToCheckForEpisodesAfter - Unix timestamp
|
||||||
|
* @param {number} maxNewEpisodes
|
||||||
|
* @returns {Promise<import('../utils/podcastUtils').RssPodcastEpisode[]|null>}
|
||||||
|
*/
|
||||||
async checkPodcastForNewEpisodes(podcastLibraryItem, dateToCheckForEpisodesAfter, maxNewEpisodes = 3) {
|
async checkPodcastForNewEpisodes(podcastLibraryItem, dateToCheckForEpisodesAfter, maxNewEpisodes = 3) {
|
||||||
if (!podcastLibraryItem.media.metadata.feedUrl) {
|
if (!podcastLibraryItem.media.feedURL) {
|
||||||
Logger.error(`[PodcastManager] checkPodcastForNewEpisodes no feed url for ${podcastLibraryItem.media.metadata.title} (ID: ${podcastLibraryItem.id})`)
|
Logger.error(`[PodcastManager] checkPodcastForNewEpisodes no feed url for ${podcastLibraryItem.media.title} (ID: ${podcastLibraryItem.id})`)
|
||||||
return false
|
return null
|
||||||
}
|
}
|
||||||
const feed = await getPodcastFeed(podcastLibraryItem.media.metadata.feedUrl)
|
const feed = await getPodcastFeed(podcastLibraryItem.media.feedURL)
|
||||||
if (!feed?.episodes) {
|
if (!feed?.episodes) {
|
||||||
Logger.error(`[PodcastManager] checkPodcastForNewEpisodes invalid feed payload for ${podcastLibraryItem.media.metadata.title} (ID: ${podcastLibraryItem.id})`, feed)
|
Logger.error(`[PodcastManager] checkPodcastForNewEpisodes invalid feed payload for ${podcastLibraryItem.media.title} (ID: ${podcastLibraryItem.id})`, feed)
|
||||||
return false
|
return null
|
||||||
}
|
}
|
||||||
|
|
||||||
// Filter new and not already has
|
// Filter new and not already has
|
||||||
@ -326,23 +378,34 @@ class PodcastManager {
|
|||||||
return newEpisodes
|
return newEpisodes
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @param {*} maxEpisodesToDownload
|
||||||
|
* @returns {Promise<import('../utils/podcastUtils').RssPodcastEpisode[]>}
|
||||||
|
*/
|
||||||
async checkAndDownloadNewEpisodes(libraryItem, maxEpisodesToDownload) {
|
async checkAndDownloadNewEpisodes(libraryItem, maxEpisodesToDownload) {
|
||||||
const lastEpisodeCheckDate = new Date(libraryItem.media.lastEpisodeCheck || 0)
|
const lastEpisodeCheck = libraryItem.media.lastEpisodeCheck?.valueOf() || 0
|
||||||
Logger.info(`[PodcastManager] checkAndDownloadNewEpisodes for "${libraryItem.media.metadata.title}" - Last episode check: ${lastEpisodeCheckDate}`)
|
const lastEpisodeCheckDate = lastEpisodeCheck > 0 ? libraryItem.media.lastEpisodeCheck : 'Never'
|
||||||
var newEpisodes = await this.checkPodcastForNewEpisodes(libraryItem, libraryItem.media.lastEpisodeCheck, maxEpisodesToDownload)
|
Logger.info(`[PodcastManager] checkAndDownloadNewEpisodes for "${libraryItem.media.title}" - Last episode check: ${lastEpisodeCheckDate}`)
|
||||||
if (newEpisodes.length) {
|
|
||||||
Logger.info(`[PodcastManager] Found ${newEpisodes.length} new episodes for podcast "${libraryItem.media.metadata.title}" - starting download`)
|
const newEpisodes = await this.checkPodcastForNewEpisodes(libraryItem, lastEpisodeCheck, maxEpisodesToDownload)
|
||||||
|
if (newEpisodes?.length) {
|
||||||
|
Logger.info(`[PodcastManager] Found ${newEpisodes.length} new episodes for podcast "${libraryItem.media.title}" - starting download`)
|
||||||
this.downloadPodcastEpisodes(libraryItem, newEpisodes, false)
|
this.downloadPodcastEpisodes(libraryItem, newEpisodes, false)
|
||||||
} else {
|
} else {
|
||||||
Logger.info(`[PodcastManager] No new episodes found for podcast "${libraryItem.media.metadata.title}"`)
|
Logger.info(`[PodcastManager] No new episodes found for podcast "${libraryItem.media.title}"`)
|
||||||
}
|
}
|
||||||
|
|
||||||
libraryItem.media.lastEpisodeCheck = Date.now()
|
libraryItem.media.lastEpisodeCheck = new Date()
|
||||||
libraryItem.updatedAt = Date.now()
|
await libraryItem.media.save()
|
||||||
await Database.updateLibraryItem(libraryItem)
|
|
||||||
SocketAuthority.emitter('item_updated', libraryItem.toJSONExpanded())
|
|
||||||
|
|
||||||
return newEpisodes
|
libraryItem.changed('updatedAt', true)
|
||||||
|
await libraryItem.save()
|
||||||
|
|
||||||
|
SocketAuthority.emitter('item_updated', libraryItem.toOldJSONExpanded())
|
||||||
|
|
||||||
|
return newEpisodes || []
|
||||||
}
|
}
|
||||||
|
|
||||||
async findEpisode(rssFeedUrl, searchTitle) {
|
async findEpisode(rssFeedUrl, searchTitle) {
|
||||||
@ -518,64 +581,123 @@ class PodcastManager {
|
|||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
const newPodcastMetadata = {
|
let newLibraryItem = null
|
||||||
title: feed.metadata.title,
|
const transaction = await Database.sequelize.transaction()
|
||||||
author: feed.metadata.author,
|
try {
|
||||||
description: feed.metadata.description,
|
const libraryItemFolderStats = await getFileTimestampsWithIno(podcastPath)
|
||||||
releaseDate: '',
|
|
||||||
genres: [...feed.metadata.categories],
|
|
||||||
feedUrl: feed.metadata.feedUrl,
|
|
||||||
imageUrl: feed.metadata.image,
|
|
||||||
itunesPageUrl: '',
|
|
||||||
itunesId: '',
|
|
||||||
itunesArtistId: '',
|
|
||||||
language: '',
|
|
||||||
numEpisodes: feed.numEpisodes
|
|
||||||
}
|
|
||||||
|
|
||||||
const libraryItemFolderStats = await getFileTimestampsWithIno(podcastPath)
|
const podcastPayload = {
|
||||||
const libraryItemPayload = {
|
autoDownloadEpisodes,
|
||||||
path: podcastPath,
|
metadata: {
|
||||||
relPath: podcastFilename,
|
title: feed.metadata.title,
|
||||||
folderId: folder.id,
|
author: feed.metadata.author,
|
||||||
libraryId: folder.libraryId,
|
description: feed.metadata.description,
|
||||||
ino: libraryItemFolderStats.ino,
|
releaseDate: '',
|
||||||
mtimeMs: libraryItemFolderStats.mtimeMs || 0,
|
genres: [...feed.metadata.categories],
|
||||||
ctimeMs: libraryItemFolderStats.ctimeMs || 0,
|
feedUrl: feed.metadata.feedUrl,
|
||||||
birthtimeMs: libraryItemFolderStats.birthtimeMs || 0,
|
imageUrl: feed.metadata.image,
|
||||||
media: {
|
itunesPageUrl: '',
|
||||||
metadata: newPodcastMetadata,
|
itunesId: '',
|
||||||
autoDownloadEpisodes
|
itunesArtistId: '',
|
||||||
|
language: '',
|
||||||
|
numEpisodes: feed.numEpisodes
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
const podcast = await Database.podcastModel.createFromRequest(podcastPayload, transaction)
|
||||||
|
|
||||||
|
newLibraryItem = await Database.libraryItemModel.create(
|
||||||
|
{
|
||||||
|
ino: libraryItemFolderStats.ino,
|
||||||
|
path: podcastPath,
|
||||||
|
relPath: podcastFilename,
|
||||||
|
mediaId: podcast.id,
|
||||||
|
mediaType: 'podcast',
|
||||||
|
isFile: false,
|
||||||
|
isMissing: false,
|
||||||
|
isInvalid: false,
|
||||||
|
mtime: libraryItemFolderStats.mtimeMs || 0,
|
||||||
|
ctime: libraryItemFolderStats.ctimeMs || 0,
|
||||||
|
birthtime: libraryItemFolderStats.birthtimeMs || 0,
|
||||||
|
size: 0,
|
||||||
|
libraryFiles: [],
|
||||||
|
extraData: {},
|
||||||
|
libraryId: folder.libraryId,
|
||||||
|
libraryFolderId: folder.id
|
||||||
|
},
|
||||||
|
{ transaction }
|
||||||
|
)
|
||||||
|
|
||||||
|
await transaction.commit()
|
||||||
|
} catch (error) {
|
||||||
|
await transaction.rollback()
|
||||||
|
Logger.error(`[PodcastManager] createPodcastsFromFeedUrls: Failed to create podcast library item for "${feed.metadata.title}"`, error)
|
||||||
|
const taskTitleStringFeed = {
|
||||||
|
text: 'OPML import feed',
|
||||||
|
key: 'MessageTaskOpmlImportFeed'
|
||||||
|
}
|
||||||
|
const taskDescriptionStringPodcast = {
|
||||||
|
text: `Creating podcast "${feed.metadata.title}"`,
|
||||||
|
key: 'MessageTaskOpmlImportFeedPodcastDescription',
|
||||||
|
subs: [feed.metadata.title]
|
||||||
|
}
|
||||||
|
const taskErrorString = {
|
||||||
|
text: 'Failed to create podcast library item',
|
||||||
|
key: 'MessageTaskOpmlImportFeedPodcastFailed'
|
||||||
|
}
|
||||||
|
TaskManager.createAndEmitFailedTask('opml-import-feed', taskTitleStringFeed, taskDescriptionStringPodcast, taskErrorString)
|
||||||
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
const libraryItem = new LibraryItem()
|
newLibraryItem.media = await newLibraryItem.getMediaExpanded()
|
||||||
libraryItem.setData('podcast', libraryItemPayload)
|
|
||||||
|
|
||||||
// Download and save cover image
|
// Download and save cover image
|
||||||
if (newPodcastMetadata.imageUrl) {
|
if (typeof feed.metadata.image === 'string' && feed.metadata.image.startsWith('http')) {
|
||||||
// TODO: Scan cover image to library files
|
|
||||||
// Podcast cover will always go into library item folder
|
// Podcast cover will always go into library item folder
|
||||||
const coverResponse = await CoverManager.downloadCoverFromUrl(libraryItem, newPodcastMetadata.imageUrl, true)
|
const coverResponse = await CoverManager.downloadCoverFromUrlNew(feed.metadata.image, newLibraryItem.id, newLibraryItem.path, true)
|
||||||
if (coverResponse) {
|
if (coverResponse.error) {
|
||||||
if (coverResponse.error) {
|
Logger.error(`[PodcastManager] Download cover error from "${feed.metadata.image}": ${coverResponse.error}`)
|
||||||
Logger.error(`[PodcastManager] createPodcastsFromFeedUrls: Download cover error from "${newPodcastMetadata.imageUrl}": ${coverResponse.error}`)
|
} else if (coverResponse.cover) {
|
||||||
} else if (coverResponse.cover) {
|
const coverImageFileStats = await getFileTimestampsWithIno(coverResponse.cover)
|
||||||
libraryItem.media.coverPath = coverResponse.cover
|
if (!coverImageFileStats) {
|
||||||
|
Logger.error(`[PodcastManager] Failed to get cover image stats for "${coverResponse.cover}"`)
|
||||||
|
} else {
|
||||||
|
// Add libraryFile to libraryItem and coverPath to podcast
|
||||||
|
const newLibraryFile = {
|
||||||
|
ino: coverImageFileStats.ino,
|
||||||
|
fileType: 'image',
|
||||||
|
addedAt: Date.now(),
|
||||||
|
updatedAt: Date.now(),
|
||||||
|
metadata: {
|
||||||
|
filename: Path.basename(coverResponse.cover),
|
||||||
|
ext: Path.extname(coverResponse.cover).slice(1),
|
||||||
|
path: coverResponse.cover,
|
||||||
|
relPath: Path.basename(coverResponse.cover),
|
||||||
|
size: coverImageFileStats.size,
|
||||||
|
mtimeMs: coverImageFileStats.mtimeMs || 0,
|
||||||
|
ctimeMs: coverImageFileStats.ctimeMs || 0,
|
||||||
|
birthtimeMs: coverImageFileStats.birthtimeMs || 0
|
||||||
|
}
|
||||||
|
}
|
||||||
|
newLibraryItem.libraryFiles.push(newLibraryFile)
|
||||||
|
newLibraryItem.changed('libraryFiles', true)
|
||||||
|
await newLibraryItem.save()
|
||||||
|
|
||||||
|
newLibraryItem.media.coverPath = coverResponse.cover
|
||||||
|
await newLibraryItem.media.save()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
await Database.createLibraryItem(libraryItem)
|
SocketAuthority.emitter('item_added', newLibraryItem.toOldJSONExpanded())
|
||||||
SocketAuthority.emitter('item_added', libraryItem.toJSONExpanded())
|
|
||||||
|
|
||||||
// Turn on podcast auto download cron if not already on
|
// Turn on podcast auto download cron if not already on
|
||||||
if (libraryItem.media.autoDownloadEpisodes) {
|
if (newLibraryItem.media.autoDownloadEpisodes) {
|
||||||
cronManager.checkUpdatePodcastCron(libraryItem)
|
cronManager.checkUpdatePodcastCron(newLibraryItem)
|
||||||
}
|
}
|
||||||
|
|
||||||
numPodcastsAdded++
|
numPodcastsAdded++
|
||||||
}
|
}
|
||||||
|
|
||||||
const taskFinishedString = {
|
const taskFinishedString = {
|
||||||
text: `Added ${numPodcastsAdded} podcasts`,
|
text: `Added ${numPodcastsAdded} podcasts`,
|
||||||
key: 'MessageTaskOpmlImportFinished',
|
key: 'MessageTaskOpmlImportFinished',
|
||||||
|
@ -107,6 +107,22 @@ class Author extends Model {
|
|||||||
return libraryItems
|
return libraryItems
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {string} name
|
||||||
|
* @param {string} libraryId
|
||||||
|
* @returns {Promise<Author>}
|
||||||
|
*/
|
||||||
|
static async findOrCreateByNameAndLibrary(name, libraryId) {
|
||||||
|
const author = await this.getByNameAndLibrary(name, libraryId)
|
||||||
|
if (author) return author
|
||||||
|
return this.create({
|
||||||
|
name,
|
||||||
|
lastFirst: this.getLastFirst(name),
|
||||||
|
libraryId
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize model
|
* Initialize model
|
||||||
* @param {import('../Database').sequelize} sequelize
|
* @param {import('../Database').sequelize} sequelize
|
||||||
|
@ -1,5 +1,7 @@
|
|||||||
const { DataTypes, Model } = require('sequelize')
|
const { DataTypes, Model } = require('sequelize')
|
||||||
const Logger = require('../Logger')
|
const Logger = require('../Logger')
|
||||||
|
const { getTitlePrefixAtEnd, getTitleIgnorePrefix } = require('../utils')
|
||||||
|
const parseNameString = require('../utils/parsers/parseNameString')
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef EBookFileObject
|
* @typedef EBookFileObject
|
||||||
@ -60,6 +62,13 @@ const Logger = require('../Logger')
|
|||||||
* @property {ChapterObject[]} chapters
|
* @property {ChapterObject[]} chapters
|
||||||
* @property {Object} metaTags
|
* @property {Object} metaTags
|
||||||
* @property {string} mimeType
|
* @property {string} mimeType
|
||||||
|
*
|
||||||
|
* @typedef AudioTrackProperties
|
||||||
|
* @property {string} title
|
||||||
|
* @property {string} contentUrl
|
||||||
|
* @property {number} startOffset
|
||||||
|
*
|
||||||
|
* @typedef {AudioFileObject & AudioTrackProperties} AudioTrack
|
||||||
*/
|
*/
|
||||||
|
|
||||||
class Book extends Model {
|
class Book extends Model {
|
||||||
@ -113,158 +122,12 @@ class Book extends Model {
|
|||||||
/** @type {Date} */
|
/** @type {Date} */
|
||||||
this.createdAt
|
this.createdAt
|
||||||
|
|
||||||
|
// Expanded properties
|
||||||
|
|
||||||
/** @type {import('./Author')[]} - optional if expanded */
|
/** @type {import('./Author')[]} - optional if expanded */
|
||||||
this.authors
|
this.authors
|
||||||
}
|
/** @type {import('./Series')[]} - optional if expanded */
|
||||||
|
this.series
|
||||||
static getOldBook(libraryItemExpanded) {
|
|
||||||
const bookExpanded = libraryItemExpanded.media
|
|
||||||
let authors = []
|
|
||||||
if (bookExpanded.authors?.length) {
|
|
||||||
authors = bookExpanded.authors.map((au) => {
|
|
||||||
return {
|
|
||||||
id: au.id,
|
|
||||||
name: au.name
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else if (bookExpanded.bookAuthors?.length) {
|
|
||||||
authors = bookExpanded.bookAuthors
|
|
||||||
.map((ba) => {
|
|
||||||
if (ba.author) {
|
|
||||||
return {
|
|
||||||
id: ba.author.id,
|
|
||||||
name: ba.author.name
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
Logger.error(`[Book] Invalid bookExpanded bookAuthors: no author`, ba)
|
|
||||||
return null
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.filter((a) => a)
|
|
||||||
}
|
|
||||||
|
|
||||||
let series = []
|
|
||||||
if (bookExpanded.series?.length) {
|
|
||||||
series = bookExpanded.series.map((se) => {
|
|
||||||
return {
|
|
||||||
id: se.id,
|
|
||||||
name: se.name,
|
|
||||||
sequence: se.bookSeries.sequence
|
|
||||||
}
|
|
||||||
})
|
|
||||||
} else if (bookExpanded.bookSeries?.length) {
|
|
||||||
series = bookExpanded.bookSeries
|
|
||||||
.map((bs) => {
|
|
||||||
if (bs.series) {
|
|
||||||
return {
|
|
||||||
id: bs.series.id,
|
|
||||||
name: bs.series.name,
|
|
||||||
sequence: bs.sequence
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
Logger.error(`[Book] Invalid bookExpanded bookSeries: no series`, bs)
|
|
||||||
return null
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.filter((s) => s)
|
|
||||||
}
|
|
||||||
|
|
||||||
return {
|
|
||||||
id: bookExpanded.id,
|
|
||||||
libraryItemId: libraryItemExpanded.id,
|
|
||||||
coverPath: bookExpanded.coverPath,
|
|
||||||
tags: bookExpanded.tags,
|
|
||||||
audioFiles: bookExpanded.audioFiles,
|
|
||||||
chapters: bookExpanded.chapters,
|
|
||||||
ebookFile: bookExpanded.ebookFile,
|
|
||||||
metadata: {
|
|
||||||
title: bookExpanded.title,
|
|
||||||
subtitle: bookExpanded.subtitle,
|
|
||||||
authors: authors,
|
|
||||||
narrators: bookExpanded.narrators,
|
|
||||||
series: series,
|
|
||||||
genres: bookExpanded.genres,
|
|
||||||
publishedYear: bookExpanded.publishedYear,
|
|
||||||
publishedDate: bookExpanded.publishedDate,
|
|
||||||
publisher: bookExpanded.publisher,
|
|
||||||
description: bookExpanded.description,
|
|
||||||
isbn: bookExpanded.isbn,
|
|
||||||
asin: bookExpanded.asin,
|
|
||||||
language: bookExpanded.language,
|
|
||||||
explicit: bookExpanded.explicit,
|
|
||||||
abridged: bookExpanded.abridged
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* @param {object} oldBook
|
|
||||||
* @returns {boolean} true if updated
|
|
||||||
*/
|
|
||||||
static saveFromOld(oldBook) {
|
|
||||||
const book = this.getFromOld(oldBook)
|
|
||||||
return this.update(book, {
|
|
||||||
where: {
|
|
||||||
id: book.id
|
|
||||||
}
|
|
||||||
})
|
|
||||||
.then((result) => result[0] > 0)
|
|
||||||
.catch((error) => {
|
|
||||||
Logger.error(`[Book] Failed to save book ${book.id}`, error)
|
|
||||||
return false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
static getFromOld(oldBook) {
|
|
||||||
return {
|
|
||||||
id: oldBook.id,
|
|
||||||
title: oldBook.metadata.title,
|
|
||||||
titleIgnorePrefix: oldBook.metadata.titleIgnorePrefix,
|
|
||||||
subtitle: oldBook.metadata.subtitle,
|
|
||||||
publishedYear: oldBook.metadata.publishedYear,
|
|
||||||
publishedDate: oldBook.metadata.publishedDate,
|
|
||||||
publisher: oldBook.metadata.publisher,
|
|
||||||
description: oldBook.metadata.description,
|
|
||||||
isbn: oldBook.metadata.isbn,
|
|
||||||
asin: oldBook.metadata.asin,
|
|
||||||
language: oldBook.metadata.language,
|
|
||||||
explicit: !!oldBook.metadata.explicit,
|
|
||||||
abridged: !!oldBook.metadata.abridged,
|
|
||||||
narrators: oldBook.metadata.narrators,
|
|
||||||
ebookFile: oldBook.ebookFile?.toJSON() || null,
|
|
||||||
coverPath: oldBook.coverPath,
|
|
||||||
duration: oldBook.duration,
|
|
||||||
audioFiles: oldBook.audioFiles?.map((af) => af.toJSON()) || [],
|
|
||||||
chapters: oldBook.chapters,
|
|
||||||
tags: oldBook.tags,
|
|
||||||
genres: oldBook.metadata.genres
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
getAbsMetadataJson() {
|
|
||||||
return {
|
|
||||||
tags: this.tags || [],
|
|
||||||
chapters: this.chapters?.map((c) => ({ ...c })) || [],
|
|
||||||
title: this.title,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
authors: this.authors.map((a) => a.name),
|
|
||||||
narrators: this.narrators,
|
|
||||||
series: this.series.map((se) => {
|
|
||||||
const sequence = se.bookSeries?.sequence || ''
|
|
||||||
if (!sequence) return se.name
|
|
||||||
return `${se.name} #${sequence}`
|
|
||||||
}),
|
|
||||||
genres: this.genres || [],
|
|
||||||
publishedYear: this.publishedYear,
|
|
||||||
publishedDate: this.publishedDate,
|
|
||||||
publisher: this.publisher,
|
|
||||||
description: this.description,
|
|
||||||
isbn: this.isbn,
|
|
||||||
asin: this.asin,
|
|
||||||
language: this.language,
|
|
||||||
explicit: !!this.explicit,
|
|
||||||
abridged: !!this.abridged
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -343,18 +206,459 @@ class Book extends Model {
|
|||||||
}
|
}
|
||||||
return this.authors.map((au) => au.name).join(', ')
|
return this.authors.map((au) => au.name).join(', ')
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Comma separated array of author names in Last, First format
|
||||||
|
* Requires authors to be loaded
|
||||||
|
*
|
||||||
|
* @returns {string}
|
||||||
|
*/
|
||||||
|
get authorNameLF() {
|
||||||
|
if (this.authors === undefined) {
|
||||||
|
Logger.error(`[Book] authorNameLF: Cannot get authorNameLF because authors are not loaded`)
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
|
||||||
|
// Last, First
|
||||||
|
if (!this.authors.length) return ''
|
||||||
|
return this.authors.map((au) => parseNameString.nameToLastFirst(au.name)).join(', ')
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Comma separated array of series with sequence
|
||||||
|
* Requires series to be loaded
|
||||||
|
*
|
||||||
|
* @returns {string}
|
||||||
|
*/
|
||||||
|
get seriesName() {
|
||||||
|
if (this.series === undefined) {
|
||||||
|
Logger.error(`[Book] seriesName: Cannot get seriesName because series are not loaded`)
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
|
||||||
|
if (!this.series.length) return ''
|
||||||
|
return this.series
|
||||||
|
.map((se) => {
|
||||||
|
const sequence = se.bookSeries?.sequence || ''
|
||||||
|
if (!sequence) return se.name
|
||||||
|
return `${se.name} #${sequence}`
|
||||||
|
})
|
||||||
|
.join(', ')
|
||||||
|
}
|
||||||
|
|
||||||
get includedAudioFiles() {
|
get includedAudioFiles() {
|
||||||
return this.audioFiles.filter((af) => !af.exclude)
|
return this.audioFiles.filter((af) => !af.exclude)
|
||||||
}
|
}
|
||||||
get trackList() {
|
|
||||||
|
get hasMediaFiles() {
|
||||||
|
return !!this.hasAudioTracks || !!this.ebookFile
|
||||||
|
}
|
||||||
|
|
||||||
|
get hasAudioTracks() {
|
||||||
|
return !!this.includedAudioFiles.length
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Supported mime types are sent from the web client and are retrieved using the browser Audio player "canPlayType" function.
|
||||||
|
*
|
||||||
|
* @param {string[]} supportedMimeTypes
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
checkCanDirectPlay(supportedMimeTypes) {
|
||||||
|
if (!Array.isArray(supportedMimeTypes)) {
|
||||||
|
Logger.error(`[Book] checkCanDirectPlay: supportedMimeTypes is not an array`, supportedMimeTypes)
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
return this.includedAudioFiles.every((af) => supportedMimeTypes.includes(af.mimeType))
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the track list to be used in client audio players
|
||||||
|
* AudioTrack is the AudioFile with startOffset, contentUrl and title
|
||||||
|
*
|
||||||
|
* @param {string} libraryItemId
|
||||||
|
* @returns {AudioTrack[]}
|
||||||
|
*/
|
||||||
|
getTracklist(libraryItemId) {
|
||||||
let startOffset = 0
|
let startOffset = 0
|
||||||
return this.includedAudioFiles.map((af) => {
|
return this.includedAudioFiles.map((af) => {
|
||||||
const track = structuredClone(af)
|
const track = structuredClone(af)
|
||||||
|
track.title = af.metadata.filename
|
||||||
track.startOffset = startOffset
|
track.startOffset = startOffset
|
||||||
|
track.contentUrl = `${global.RouterBasePath}/api/items/${libraryItemId}/file/${track.ino}`
|
||||||
startOffset += track.duration
|
startOffset += track.duration
|
||||||
return track
|
return track
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @returns {ChapterObject[]}
|
||||||
|
*/
|
||||||
|
getChapters() {
|
||||||
|
return structuredClone(this.chapters) || []
|
||||||
|
}
|
||||||
|
|
||||||
|
getPlaybackTitle() {
|
||||||
|
return this.title
|
||||||
|
}
|
||||||
|
|
||||||
|
getPlaybackAuthor() {
|
||||||
|
return this.authorName
|
||||||
|
}
|
||||||
|
|
||||||
|
getPlaybackDuration() {
|
||||||
|
return this.duration
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Total file size of all audio files and ebook file
|
||||||
|
*
|
||||||
|
* @returns {number}
|
||||||
|
*/
|
||||||
|
get size() {
|
||||||
|
let total = 0
|
||||||
|
this.audioFiles.forEach((af) => (total += af.metadata.size))
|
||||||
|
if (this.ebookFile) {
|
||||||
|
total += this.ebookFile.metadata.size
|
||||||
|
}
|
||||||
|
return total
|
||||||
|
}
|
||||||
|
|
||||||
|
getAbsMetadataJson() {
|
||||||
|
return {
|
||||||
|
tags: this.tags || [],
|
||||||
|
chapters: this.chapters?.map((c) => ({ ...c })) || [],
|
||||||
|
title: this.title,
|
||||||
|
subtitle: this.subtitle,
|
||||||
|
authors: this.authors.map((a) => a.name),
|
||||||
|
narrators: this.narrators,
|
||||||
|
series: this.series.map((se) => {
|
||||||
|
const sequence = se.bookSeries?.sequence || ''
|
||||||
|
if (!sequence) return se.name
|
||||||
|
return `${se.name} #${sequence}`
|
||||||
|
}),
|
||||||
|
genres: this.genres || [],
|
||||||
|
publishedYear: this.publishedYear,
|
||||||
|
publishedDate: this.publishedDate,
|
||||||
|
publisher: this.publisher,
|
||||||
|
description: this.description,
|
||||||
|
isbn: this.isbn,
|
||||||
|
asin: this.asin,
|
||||||
|
language: this.language,
|
||||||
|
explicit: !!this.explicit,
|
||||||
|
abridged: !!this.abridged
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {Object} payload - old book object
|
||||||
|
* @returns {Promise<boolean>}
|
||||||
|
*/
|
||||||
|
async updateFromRequest(payload) {
|
||||||
|
if (!payload) return false
|
||||||
|
|
||||||
|
let hasUpdates = false
|
||||||
|
|
||||||
|
if (payload.metadata) {
|
||||||
|
const metadataStringKeys = ['title', 'subtitle', 'publishedYear', 'publishedDate', 'publisher', 'description', 'isbn', 'asin', 'language']
|
||||||
|
metadataStringKeys.forEach((key) => {
|
||||||
|
if (typeof payload.metadata[key] === 'string' && this[key] !== payload.metadata[key]) {
|
||||||
|
this[key] = payload.metadata[key] || null
|
||||||
|
|
||||||
|
if (key === 'title') {
|
||||||
|
this.titleIgnorePrefix = getTitleIgnorePrefix(this.title)
|
||||||
|
}
|
||||||
|
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if (payload.metadata.explicit !== undefined && this.explicit !== !!payload.metadata.explicit) {
|
||||||
|
this.explicit = !!payload.metadata.explicit
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
if (payload.metadata.abridged !== undefined && this.abridged !== !!payload.metadata.abridged) {
|
||||||
|
this.abridged = !!payload.metadata.abridged
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
const arrayOfStringsKeys = ['narrators', 'genres']
|
||||||
|
arrayOfStringsKeys.forEach((key) => {
|
||||||
|
if (Array.isArray(payload.metadata[key]) && !payload.metadata[key].some((item) => typeof item !== 'string') && JSON.stringify(this[key]) !== JSON.stringify(payload.metadata[key])) {
|
||||||
|
this[key] = payload.metadata[key]
|
||||||
|
this.changed(key, true)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Array.isArray(payload.tags) && !payload.tags.some((tag) => typeof tag !== 'string') && JSON.stringify(this.tags) !== JSON.stringify(payload.tags)) {
|
||||||
|
this.tags = payload.tags
|
||||||
|
this.changed('tags', true)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
|
||||||
|
// TODO: Remove support for updating audioFiles, chapters and ebookFile here
|
||||||
|
const arrayOfObjectsKeys = ['audioFiles', 'chapters']
|
||||||
|
arrayOfObjectsKeys.forEach((key) => {
|
||||||
|
if (Array.isArray(payload[key]) && !payload[key].some((item) => typeof item !== 'object') && JSON.stringify(this[key]) !== JSON.stringify(payload[key])) {
|
||||||
|
this[key] = payload[key]
|
||||||
|
this.changed(key, true)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
if (payload.ebookFile && JSON.stringify(this.ebookFile) !== JSON.stringify(payload.ebookFile)) {
|
||||||
|
this.ebookFile = payload.ebookFile
|
||||||
|
this.changed('ebookFile', true)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
|
||||||
|
if (hasUpdates) {
|
||||||
|
Logger.debug(`[Book] "${this.title}" changed keys:`, this.changed())
|
||||||
|
await this.save()
|
||||||
|
}
|
||||||
|
|
||||||
|
return hasUpdates
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates or removes authors from the book using the author names from the request
|
||||||
|
*
|
||||||
|
* @param {string[]} authors
|
||||||
|
* @param {string} libraryId
|
||||||
|
* @returns {Promise<{authorsRemoved: import('./Author')[], authorsAdded: import('./Author')[]}>}
|
||||||
|
*/
|
||||||
|
async updateAuthorsFromRequest(authors, libraryId) {
|
||||||
|
if (!Array.isArray(authors)) return null
|
||||||
|
|
||||||
|
if (!this.authors) {
|
||||||
|
throw new Error(`[Book] Cannot update authors because authors are not loaded for book ${this.id}`)
|
||||||
|
}
|
||||||
|
|
||||||
|
/** @type {typeof import('./Author')} */
|
||||||
|
const authorModel = this.sequelize.models.author
|
||||||
|
|
||||||
|
/** @type {typeof import('./BookAuthor')} */
|
||||||
|
const bookAuthorModel = this.sequelize.models.bookAuthor
|
||||||
|
|
||||||
|
const authorsCleaned = authors.map((a) => a.toLowerCase()).filter((a) => a)
|
||||||
|
const authorsRemoved = this.authors.filter((au) => !authorsCleaned.includes(au.name.toLowerCase()))
|
||||||
|
const newAuthorNames = authors.filter((a) => !this.authors.some((au) => au.name.toLowerCase() === a.toLowerCase()))
|
||||||
|
|
||||||
|
for (const author of authorsRemoved) {
|
||||||
|
await bookAuthorModel.removeByIds(author.id, this.id)
|
||||||
|
Logger.debug(`[Book] "${this.title}" Removed author "${author.name}"`)
|
||||||
|
this.authors = this.authors.filter((au) => au.id !== author.id)
|
||||||
|
}
|
||||||
|
const authorsAdded = []
|
||||||
|
for (const authorName of newAuthorNames) {
|
||||||
|
const author = await authorModel.findOrCreateByNameAndLibrary(authorName, libraryId)
|
||||||
|
await bookAuthorModel.create({ bookId: this.id, authorId: author.id })
|
||||||
|
Logger.debug(`[Book] "${this.title}" Added author "${author.name}"`)
|
||||||
|
this.authors.push(author)
|
||||||
|
authorsAdded.push(author)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
authorsRemoved,
|
||||||
|
authorsAdded
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Creates or removes series from the book using the series names from the request.
|
||||||
|
* Updates series sequence if it has changed.
|
||||||
|
*
|
||||||
|
* @param {{ name: string, sequence: string }[]} seriesObjects
|
||||||
|
* @param {string} libraryId
|
||||||
|
* @returns {Promise<{seriesRemoved: import('./Series')[], seriesAdded: import('./Series')[], hasUpdates: boolean}>}
|
||||||
|
*/
|
||||||
|
async updateSeriesFromRequest(seriesObjects, libraryId) {
|
||||||
|
if (!Array.isArray(seriesObjects) || seriesObjects.some((se) => !se.name || typeof se.name !== 'string')) return null
|
||||||
|
|
||||||
|
if (!this.series) {
|
||||||
|
throw new Error(`[Book] Cannot update series because series are not loaded for book ${this.id}`)
|
||||||
|
}
|
||||||
|
|
||||||
|
/** @type {typeof import('./Series')} */
|
||||||
|
const seriesModel = this.sequelize.models.series
|
||||||
|
|
||||||
|
/** @type {typeof import('./BookSeries')} */
|
||||||
|
const bookSeriesModel = this.sequelize.models.bookSeries
|
||||||
|
|
||||||
|
const seriesNamesCleaned = seriesObjects.map((se) => se.name.toLowerCase())
|
||||||
|
const seriesRemoved = this.series.filter((se) => !seriesNamesCleaned.includes(se.name.toLowerCase()))
|
||||||
|
const seriesAdded = []
|
||||||
|
let hasUpdates = false
|
||||||
|
for (const seriesObj of seriesObjects) {
|
||||||
|
const seriesObjSequence = typeof seriesObj.sequence === 'string' ? seriesObj.sequence : null
|
||||||
|
|
||||||
|
const existingSeries = this.series.find((se) => se.name.toLowerCase() === seriesObj.name.toLowerCase())
|
||||||
|
if (existingSeries) {
|
||||||
|
if (existingSeries.bookSeries.sequence !== seriesObjSequence) {
|
||||||
|
existingSeries.bookSeries.sequence = seriesObjSequence
|
||||||
|
await existingSeries.bookSeries.save()
|
||||||
|
hasUpdates = true
|
||||||
|
Logger.debug(`[Book] "${this.title}" Updated series "${existingSeries.name}" sequence ${seriesObjSequence}`)
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
const series = await seriesModel.findOrCreateByNameAndLibrary(seriesObj.name, libraryId)
|
||||||
|
series.bookSeries = await bookSeriesModel.create({ bookId: this.id, seriesId: series.id, sequence: seriesObjSequence })
|
||||||
|
this.series.push(series)
|
||||||
|
seriesAdded.push(series)
|
||||||
|
hasUpdates = true
|
||||||
|
Logger.debug(`[Book] "${this.title}" Added series "${series.name}"`)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
for (const series of seriesRemoved) {
|
||||||
|
await bookSeriesModel.removeByIds(series.id, this.id)
|
||||||
|
this.series = this.series.filter((se) => se.id !== series.id)
|
||||||
|
Logger.debug(`[Book] "${this.title}" Removed series ${series.id}`)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
seriesRemoved,
|
||||||
|
seriesAdded,
|
||||||
|
hasUpdates
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Old model kept metadata in a separate object
|
||||||
|
*/
|
||||||
|
oldMetadataToJSON() {
|
||||||
|
const authors = this.authors.map((au) => ({ id: au.id, name: au.name }))
|
||||||
|
const series = this.series.map((se) => ({ id: se.id, name: se.name, sequence: se.bookSeries.sequence }))
|
||||||
|
return {
|
||||||
|
title: this.title,
|
||||||
|
subtitle: this.subtitle,
|
||||||
|
authors,
|
||||||
|
narrators: [...(this.narrators || [])],
|
||||||
|
series,
|
||||||
|
genres: [...(this.genres || [])],
|
||||||
|
publishedYear: this.publishedYear,
|
||||||
|
publishedDate: this.publishedDate,
|
||||||
|
publisher: this.publisher,
|
||||||
|
description: this.description,
|
||||||
|
isbn: this.isbn,
|
||||||
|
asin: this.asin,
|
||||||
|
language: this.language,
|
||||||
|
explicit: this.explicit,
|
||||||
|
abridged: this.abridged
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
oldMetadataToJSONMinified() {
|
||||||
|
return {
|
||||||
|
title: this.title,
|
||||||
|
titleIgnorePrefix: getTitlePrefixAtEnd(this.title),
|
||||||
|
subtitle: this.subtitle,
|
||||||
|
authorName: this.authorName,
|
||||||
|
authorNameLF: this.authorNameLF,
|
||||||
|
narratorName: (this.narrators || []).join(', '),
|
||||||
|
seriesName: this.seriesName,
|
||||||
|
genres: [...(this.genres || [])],
|
||||||
|
publishedYear: this.publishedYear,
|
||||||
|
publishedDate: this.publishedDate,
|
||||||
|
publisher: this.publisher,
|
||||||
|
description: this.description,
|
||||||
|
isbn: this.isbn,
|
||||||
|
asin: this.asin,
|
||||||
|
language: this.language,
|
||||||
|
explicit: this.explicit,
|
||||||
|
abridged: this.abridged
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
oldMetadataToJSONExpanded() {
|
||||||
|
const oldMetadataJSON = this.oldMetadataToJSON()
|
||||||
|
oldMetadataJSON.titleIgnorePrefix = getTitlePrefixAtEnd(this.title)
|
||||||
|
oldMetadataJSON.authorName = this.authorName
|
||||||
|
oldMetadataJSON.authorNameLF = this.authorNameLF
|
||||||
|
oldMetadataJSON.narratorName = (this.narrators || []).join(', ')
|
||||||
|
oldMetadataJSON.seriesName = this.seriesName
|
||||||
|
return oldMetadataJSON
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The old model stored a minified series and authors array with the book object.
|
||||||
|
* Minified series is { id, name, sequence }
|
||||||
|
* Minified author is { id, name }
|
||||||
|
*
|
||||||
|
* @param {string} libraryItemId
|
||||||
|
*/
|
||||||
|
toOldJSON(libraryItemId) {
|
||||||
|
if (!libraryItemId) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because libraryItemId is not provided`)
|
||||||
|
}
|
||||||
|
if (!this.authors) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because authors are not loaded`)
|
||||||
|
}
|
||||||
|
if (!this.series) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because series are not loaded`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
libraryItemId: libraryItemId,
|
||||||
|
metadata: this.oldMetadataToJSON(),
|
||||||
|
coverPath: this.coverPath,
|
||||||
|
tags: [...(this.tags || [])],
|
||||||
|
audioFiles: structuredClone(this.audioFiles),
|
||||||
|
chapters: structuredClone(this.chapters),
|
||||||
|
ebookFile: structuredClone(this.ebookFile)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSONMinified() {
|
||||||
|
if (!this.authors) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because authors are not loaded`)
|
||||||
|
}
|
||||||
|
if (!this.series) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because series are not loaded`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
metadata: this.oldMetadataToJSONMinified(),
|
||||||
|
coverPath: this.coverPath,
|
||||||
|
tags: [...(this.tags || [])],
|
||||||
|
numTracks: this.includedAudioFiles.length,
|
||||||
|
numAudioFiles: this.audioFiles?.length || 0,
|
||||||
|
numChapters: this.chapters?.length || 0,
|
||||||
|
duration: this.duration,
|
||||||
|
size: this.size,
|
||||||
|
ebookFormat: this.ebookFile?.ebookFormat
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSONExpanded(libraryItemId) {
|
||||||
|
if (!libraryItemId) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because libraryItemId is not provided`)
|
||||||
|
}
|
||||||
|
if (!this.authors) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because authors are not loaded`)
|
||||||
|
}
|
||||||
|
if (!this.series) {
|
||||||
|
throw new Error(`[Book] Cannot convert to old JSON because series are not loaded`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
libraryItemId: libraryItemId,
|
||||||
|
metadata: this.oldMetadataToJSONExpanded(),
|
||||||
|
coverPath: this.coverPath,
|
||||||
|
tags: [...(this.tags || [])],
|
||||||
|
audioFiles: structuredClone(this.audioFiles),
|
||||||
|
chapters: structuredClone(this.chapters),
|
||||||
|
ebookFile: structuredClone(this.ebookFile),
|
||||||
|
duration: this.duration,
|
||||||
|
size: this.size,
|
||||||
|
tracks: this.getTracklist(libraryItemId)
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = Book
|
module.exports = Book
|
||||||
|
@ -282,7 +282,7 @@ class Collection extends Model {
|
|||||||
const libraryItem = book.libraryItem
|
const libraryItem = book.libraryItem
|
||||||
delete book.libraryItem
|
delete book.libraryItem
|
||||||
libraryItem.media = book
|
libraryItem.media = book
|
||||||
return this.sequelize.models.libraryItem.getOldLibraryItem(libraryItem).toJSONExpanded()
|
return libraryItem.toOldJSONExpanded()
|
||||||
})
|
})
|
||||||
|
|
||||||
return json
|
return json
|
||||||
|
@ -112,15 +112,15 @@ class FeedEpisode extends Model {
|
|||||||
/**
|
/**
|
||||||
* If chapters for an audiobook match the audio tracks then use chapter titles instead of audio file names
|
* If chapters for an audiobook match the audio tracks then use chapter titles instead of audio file names
|
||||||
*
|
*
|
||||||
|
* @param {import('./Book').AudioTrack[]} trackList
|
||||||
* @param {import('./Book')} book
|
* @param {import('./Book')} book
|
||||||
* @returns {boolean}
|
* @returns {boolean}
|
||||||
*/
|
*/
|
||||||
static checkUseChapterTitlesForEpisodes(book) {
|
static checkUseChapterTitlesForEpisodes(trackList, book) {
|
||||||
const tracks = book.trackList || []
|
|
||||||
const chapters = book.chapters || []
|
const chapters = book.chapters || []
|
||||||
if (tracks.length !== chapters.length) return false
|
if (trackList.length !== chapters.length) return false
|
||||||
for (let i = 0; i < tracks.length; i++) {
|
for (let i = 0; i < trackList.length; i++) {
|
||||||
if (Math.abs(chapters[i].start - tracks[i].startOffset) >= 1) {
|
if (Math.abs(chapters[i].start - trackList[i].startOffset) >= 1) {
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -139,7 +139,8 @@ class FeedEpisode extends Model {
|
|||||||
*/
|
*/
|
||||||
static getFeedEpisodeObjFromAudiobookTrack(book, pubDateStart, feed, slug, audioTrack, useChapterTitles, existingEpisodeId = null) {
|
static getFeedEpisodeObjFromAudiobookTrack(book, pubDateStart, feed, slug, audioTrack, useChapterTitles, existingEpisodeId = null) {
|
||||||
// Example: <pubDate>Fri, 04 Feb 2015 00:00:00 GMT</pubDate>
|
// Example: <pubDate>Fri, 04 Feb 2015 00:00:00 GMT</pubDate>
|
||||||
let timeOffset = isNaN(audioTrack.index) ? 0 : Number(audioTrack.index) * 1000 // Offset pubdate to ensure correct order
|
// Offset pubdate in 1 minute intervals to ensure correct order
|
||||||
|
let timeOffset = isNaN(audioTrack.index) ? 0 : Number(audioTrack.index) * 60000
|
||||||
let episodeId = existingEpisodeId || uuidv4()
|
let episodeId = existingEpisodeId || uuidv4()
|
||||||
|
|
||||||
// e.g. Track 1 will have a pub date before Track 2
|
// e.g. Track 1 will have a pub date before Track 2
|
||||||
@ -148,7 +149,7 @@ class FeedEpisode extends Model {
|
|||||||
const contentUrl = `/feed/${slug}/item/${episodeId}/media${Path.extname(audioTrack.metadata.filename)}`
|
const contentUrl = `/feed/${slug}/item/${episodeId}/media${Path.extname(audioTrack.metadata.filename)}`
|
||||||
|
|
||||||
let title = Path.basename(audioTrack.metadata.filename, Path.extname(audioTrack.metadata.filename))
|
let title = Path.basename(audioTrack.metadata.filename, Path.extname(audioTrack.metadata.filename))
|
||||||
if (book.trackList.length == 1) {
|
if (book.includedAudioFiles.length == 1) {
|
||||||
// If audiobook is a single file, use book title instead of chapter/file title
|
// If audiobook is a single file, use book title instead of chapter/file title
|
||||||
title = book.title
|
title = book.title
|
||||||
} else {
|
} else {
|
||||||
@ -185,11 +186,12 @@ class FeedEpisode extends Model {
|
|||||||
* @returns {Promise<FeedEpisode[]>}
|
* @returns {Promise<FeedEpisode[]>}
|
||||||
*/
|
*/
|
||||||
static async createFromAudiobookTracks(libraryItemExpanded, feed, slug, transaction) {
|
static async createFromAudiobookTracks(libraryItemExpanded, feed, slug, transaction) {
|
||||||
const useChapterTitles = this.checkUseChapterTitlesForEpisodes(libraryItemExpanded.media)
|
const trackList = libraryItemExpanded.getTrackList()
|
||||||
|
const useChapterTitles = this.checkUseChapterTitlesForEpisodes(trackList, libraryItemExpanded.media)
|
||||||
|
|
||||||
const feedEpisodeObjs = []
|
const feedEpisodeObjs = []
|
||||||
let numExisting = 0
|
let numExisting = 0
|
||||||
for (const track of libraryItemExpanded.media.trackList) {
|
for (const track of trackList) {
|
||||||
// Check for existing episode by filepath
|
// Check for existing episode by filepath
|
||||||
const existingEpisode = feed.feedEpisodes?.find((episode) => {
|
const existingEpisode = feed.feedEpisodes?.find((episode) => {
|
||||||
return episode.filePath === track.metadata.path
|
return episode.filePath === track.metadata.path
|
||||||
@ -204,7 +206,7 @@ class FeedEpisode extends Model {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {import('./Book')[]} books
|
* @param {import('./Book').BookExpandedWithLibraryItem[]} books
|
||||||
* @param {import('./Feed')} feed
|
* @param {import('./Feed')} feed
|
||||||
* @param {string} slug
|
* @param {string} slug
|
||||||
* @param {import('sequelize').Transaction} transaction
|
* @param {import('sequelize').Transaction} transaction
|
||||||
@ -218,8 +220,9 @@ class FeedEpisode extends Model {
|
|||||||
const feedEpisodeObjs = []
|
const feedEpisodeObjs = []
|
||||||
let numExisting = 0
|
let numExisting = 0
|
||||||
for (const book of books) {
|
for (const book of books) {
|
||||||
const useChapterTitles = this.checkUseChapterTitlesForEpisodes(book)
|
const trackList = book.libraryItem.getTrackList()
|
||||||
for (const track of book.trackList) {
|
const useChapterTitles = this.checkUseChapterTitlesForEpisodes(trackList, book)
|
||||||
|
for (const track of trackList) {
|
||||||
// Check for existing episode by filepath
|
// Check for existing episode by filepath
|
||||||
const existingEpisode = feed.feedEpisodes?.find((episode) => {
|
const existingEpisode = feed.feedEpisodes?.find((episode) => {
|
||||||
return episode.filePath === track.metadata.path
|
return episode.filePath === track.metadata.path
|
||||||
|
@ -1,11 +1,8 @@
|
|||||||
const util = require('util')
|
|
||||||
const Path = require('path')
|
const Path = require('path')
|
||||||
const { DataTypes, Model } = require('sequelize')
|
const { DataTypes, Model } = require('sequelize')
|
||||||
const fsExtra = require('../libs/fsExtra')
|
const fsExtra = require('../libs/fsExtra')
|
||||||
const Logger = require('../Logger')
|
const Logger = require('../Logger')
|
||||||
const oldLibraryItem = require('../objects/LibraryItem')
|
|
||||||
const libraryFilters = require('../utils/queries/libraryFilters')
|
const libraryFilters = require('../utils/queries/libraryFilters')
|
||||||
const { areEquivalent } = require('../utils/index')
|
|
||||||
const { filePathToPOSIX, getFileTimestampsWithIno } = require('../utils/fileUtils')
|
const { filePathToPOSIX, getFileTimestampsWithIno } = require('../utils/fileUtils')
|
||||||
const LibraryFile = require('../objects/files/LibraryFile')
|
const LibraryFile = require('../objects/files/LibraryFile')
|
||||||
const Book = require('./Book')
|
const Book = require('./Book')
|
||||||
@ -123,12 +120,27 @@ class LibraryItem extends Model {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* Remove library item by id
|
||||||
*
|
*
|
||||||
* @param {import('sequelize').WhereOptions} [where]
|
* @param {string} libraryItemId
|
||||||
* @returns {Array<objects.LibraryItem>} old library items
|
* @returns {Promise<number>} The number of destroyed rows
|
||||||
*/
|
*/
|
||||||
static async getAllOldLibraryItems(where = null) {
|
static removeById(libraryItemId) {
|
||||||
let libraryItems = await this.findAll({
|
return this.destroy({
|
||||||
|
where: {
|
||||||
|
id: libraryItemId
|
||||||
|
},
|
||||||
|
individualHooks: true
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('sequelize').WhereOptions} where
|
||||||
|
* @returns {Promise<LibraryItemExpanded[]>}
|
||||||
|
*/
|
||||||
|
static async findAllExpandedWhere(where = null) {
|
||||||
|
return this.findAll({
|
||||||
where,
|
where,
|
||||||
include: [
|
include: [
|
||||||
{
|
{
|
||||||
@ -150,302 +162,17 @@ class LibraryItem extends Model {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
model: this.sequelize.models.podcast,
|
model: this.sequelize.models.podcast,
|
||||||
include: [
|
include: {
|
||||||
{
|
model: this.sequelize.models.podcastEpisode
|
||||||
model: this.sequelize.models.podcastEpisode
|
}
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
|
],
|
||||||
|
order: [
|
||||||
|
// Ensure author & series stay in the same order
|
||||||
|
[this.sequelize.models.book, this.sequelize.models.author, this.sequelize.models.bookAuthor, 'createdAt', 'ASC'],
|
||||||
|
[this.sequelize.models.book, this.sequelize.models.series, 'bookSeries', 'createdAt', 'ASC']
|
||||||
]
|
]
|
||||||
})
|
})
|
||||||
return libraryItems.map((ti) => this.getOldLibraryItem(ti))
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Convert an expanded LibraryItem into an old library item
|
|
||||||
*
|
|
||||||
* @param {Model<LibraryItem>} libraryItemExpanded
|
|
||||||
* @returns {oldLibraryItem}
|
|
||||||
*/
|
|
||||||
static getOldLibraryItem(libraryItemExpanded) {
|
|
||||||
let media = null
|
|
||||||
if (libraryItemExpanded.mediaType === 'book') {
|
|
||||||
media = this.sequelize.models.book.getOldBook(libraryItemExpanded)
|
|
||||||
} else if (libraryItemExpanded.mediaType === 'podcast') {
|
|
||||||
media = this.sequelize.models.podcast.getOldPodcast(libraryItemExpanded)
|
|
||||||
}
|
|
||||||
|
|
||||||
return new oldLibraryItem({
|
|
||||||
id: libraryItemExpanded.id,
|
|
||||||
ino: libraryItemExpanded.ino,
|
|
||||||
oldLibraryItemId: libraryItemExpanded.extraData?.oldLibraryItemId || null,
|
|
||||||
libraryId: libraryItemExpanded.libraryId,
|
|
||||||
folderId: libraryItemExpanded.libraryFolderId,
|
|
||||||
path: libraryItemExpanded.path,
|
|
||||||
relPath: libraryItemExpanded.relPath,
|
|
||||||
isFile: libraryItemExpanded.isFile,
|
|
||||||
mtimeMs: libraryItemExpanded.mtime?.valueOf(),
|
|
||||||
ctimeMs: libraryItemExpanded.ctime?.valueOf(),
|
|
||||||
birthtimeMs: libraryItemExpanded.birthtime?.valueOf(),
|
|
||||||
addedAt: libraryItemExpanded.createdAt.valueOf(),
|
|
||||||
updatedAt: libraryItemExpanded.updatedAt.valueOf(),
|
|
||||||
lastScan: libraryItemExpanded.lastScan?.valueOf(),
|
|
||||||
scanVersion: libraryItemExpanded.lastScanVersion,
|
|
||||||
isMissing: !!libraryItemExpanded.isMissing,
|
|
||||||
isInvalid: !!libraryItemExpanded.isInvalid,
|
|
||||||
mediaType: libraryItemExpanded.mediaType,
|
|
||||||
media,
|
|
||||||
libraryFiles: libraryItemExpanded.libraryFiles
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
static async fullCreateFromOld(oldLibraryItem) {
|
|
||||||
const newLibraryItem = await this.create(this.getFromOld(oldLibraryItem))
|
|
||||||
|
|
||||||
if (oldLibraryItem.mediaType === 'book') {
|
|
||||||
const bookObj = this.sequelize.models.book.getFromOld(oldLibraryItem.media)
|
|
||||||
bookObj.libraryItemId = newLibraryItem.id
|
|
||||||
const newBook = await this.sequelize.models.book.create(bookObj)
|
|
||||||
|
|
||||||
const oldBookAuthors = oldLibraryItem.media.metadata.authors || []
|
|
||||||
const oldBookSeriesAll = oldLibraryItem.media.metadata.series || []
|
|
||||||
|
|
||||||
for (const oldBookAuthor of oldBookAuthors) {
|
|
||||||
await this.sequelize.models.bookAuthor.create({ authorId: oldBookAuthor.id, bookId: newBook.id })
|
|
||||||
}
|
|
||||||
for (const oldSeries of oldBookSeriesAll) {
|
|
||||||
await this.sequelize.models.bookSeries.create({ seriesId: oldSeries.id, bookId: newBook.id, sequence: oldSeries.sequence })
|
|
||||||
}
|
|
||||||
} else if (oldLibraryItem.mediaType === 'podcast') {
|
|
||||||
const podcastObj = this.sequelize.models.podcast.getFromOld(oldLibraryItem.media)
|
|
||||||
podcastObj.libraryItemId = newLibraryItem.id
|
|
||||||
const newPodcast = await this.sequelize.models.podcast.create(podcastObj)
|
|
||||||
|
|
||||||
const oldEpisodes = oldLibraryItem.media.episodes || []
|
|
||||||
for (const oldEpisode of oldEpisodes) {
|
|
||||||
const episodeObj = this.sequelize.models.podcastEpisode.getFromOld(oldEpisode)
|
|
||||||
episodeObj.libraryItemId = newLibraryItem.id
|
|
||||||
episodeObj.podcastId = newPodcast.id
|
|
||||||
await this.sequelize.models.podcastEpisode.create(episodeObj)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return newLibraryItem
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Updates libraryItem, book, authors and series from old library item
|
|
||||||
*
|
|
||||||
* @param {oldLibraryItem} oldLibraryItem
|
|
||||||
* @returns {Promise<boolean>} true if updates were made
|
|
||||||
*/
|
|
||||||
static async fullUpdateFromOld(oldLibraryItem) {
|
|
||||||
const libraryItemExpanded = await this.getExpandedById(oldLibraryItem.id)
|
|
||||||
if (!libraryItemExpanded) return false
|
|
||||||
|
|
||||||
let hasUpdates = false
|
|
||||||
|
|
||||||
// Check update Book/Podcast
|
|
||||||
if (libraryItemExpanded.media) {
|
|
||||||
let updatedMedia = null
|
|
||||||
if (libraryItemExpanded.mediaType === 'podcast') {
|
|
||||||
updatedMedia = this.sequelize.models.podcast.getFromOld(oldLibraryItem.media)
|
|
||||||
|
|
||||||
const existingPodcastEpisodes = libraryItemExpanded.media.podcastEpisodes || []
|
|
||||||
const updatedPodcastEpisodes = oldLibraryItem.media.episodes || []
|
|
||||||
|
|
||||||
for (const existingPodcastEpisode of existingPodcastEpisodes) {
|
|
||||||
// Episode was removed
|
|
||||||
if (!updatedPodcastEpisodes.some((ep) => ep.id === existingPodcastEpisode.id)) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" episode "${existingPodcastEpisode.title}" was removed`)
|
|
||||||
await existingPodcastEpisode.destroy()
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (const updatedPodcastEpisode of updatedPodcastEpisodes) {
|
|
||||||
const existingEpisodeMatch = existingPodcastEpisodes.find((ep) => ep.id === updatedPodcastEpisode.id)
|
|
||||||
if (!existingEpisodeMatch) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" episode "${updatedPodcastEpisode.title}" was added`)
|
|
||||||
await this.sequelize.models.podcastEpisode.createFromOld(updatedPodcastEpisode)
|
|
||||||
hasUpdates = true
|
|
||||||
} else {
|
|
||||||
const updatedEpisodeCleaned = this.sequelize.models.podcastEpisode.getFromOld(updatedPodcastEpisode)
|
|
||||||
let episodeHasUpdates = false
|
|
||||||
for (const key in updatedEpisodeCleaned) {
|
|
||||||
let existingValue = existingEpisodeMatch[key]
|
|
||||||
if (existingValue instanceof Date) existingValue = existingValue.valueOf()
|
|
||||||
|
|
||||||
if (!areEquivalent(updatedEpisodeCleaned[key], existingValue, true)) {
|
|
||||||
Logger.debug(util.format(`[LibraryItem] "${libraryItemExpanded.media.title}" episode "${existingEpisodeMatch.title}" ${key} was updated from %j to %j`, existingValue, updatedEpisodeCleaned[key]))
|
|
||||||
episodeHasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (episodeHasUpdates) {
|
|
||||||
await existingEpisodeMatch.update(updatedEpisodeCleaned)
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
} else if (libraryItemExpanded.mediaType === 'book') {
|
|
||||||
updatedMedia = this.sequelize.models.book.getFromOld(oldLibraryItem.media)
|
|
||||||
|
|
||||||
const existingAuthors = libraryItemExpanded.media.authors || []
|
|
||||||
const existingSeriesAll = libraryItemExpanded.media.series || []
|
|
||||||
const updatedAuthors = oldLibraryItem.media.metadata.authors || []
|
|
||||||
const uniqueUpdatedAuthors = updatedAuthors.filter((au, idx) => updatedAuthors.findIndex((a) => a.id === au.id) === idx)
|
|
||||||
const updatedSeriesAll = oldLibraryItem.media.metadata.series || []
|
|
||||||
|
|
||||||
for (const existingAuthor of existingAuthors) {
|
|
||||||
// Author was removed from Book
|
|
||||||
if (!uniqueUpdatedAuthors.some((au) => au.id === existingAuthor.id)) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" author "${existingAuthor.name}" was removed`)
|
|
||||||
await this.sequelize.models.bookAuthor.removeByIds(existingAuthor.id, libraryItemExpanded.media.id)
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (const updatedAuthor of uniqueUpdatedAuthors) {
|
|
||||||
// Author was added
|
|
||||||
if (!existingAuthors.some((au) => au.id === updatedAuthor.id)) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" author "${updatedAuthor.name}" was added`)
|
|
||||||
await this.sequelize.models.bookAuthor.create({ authorId: updatedAuthor.id, bookId: libraryItemExpanded.media.id })
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (const existingSeries of existingSeriesAll) {
|
|
||||||
// Series was removed
|
|
||||||
if (!updatedSeriesAll.some((se) => se.id === existingSeries.id)) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" series "${existingSeries.name}" was removed`)
|
|
||||||
await this.sequelize.models.bookSeries.removeByIds(existingSeries.id, libraryItemExpanded.media.id)
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
for (const updatedSeries of updatedSeriesAll) {
|
|
||||||
// Series was added/updated
|
|
||||||
const existingSeriesMatch = existingSeriesAll.find((se) => se.id === updatedSeries.id)
|
|
||||||
if (!existingSeriesMatch) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" series "${updatedSeries.name}" was added`)
|
|
||||||
await this.sequelize.models.bookSeries.create({ seriesId: updatedSeries.id, bookId: libraryItemExpanded.media.id, sequence: updatedSeries.sequence })
|
|
||||||
hasUpdates = true
|
|
||||||
} else if (existingSeriesMatch.bookSeries.sequence !== updatedSeries.sequence) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" series "${updatedSeries.name}" sequence was updated from "${existingSeriesMatch.bookSeries.sequence}" to "${updatedSeries.sequence}"`)
|
|
||||||
await existingSeriesMatch.bookSeries.update({ id: updatedSeries.id, sequence: updatedSeries.sequence })
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
let hasMediaUpdates = false
|
|
||||||
for (const key in updatedMedia) {
|
|
||||||
let existingValue = libraryItemExpanded.media[key]
|
|
||||||
if (existingValue instanceof Date) existingValue = existingValue.valueOf()
|
|
||||||
|
|
||||||
if (!areEquivalent(updatedMedia[key], existingValue, true)) {
|
|
||||||
if (key === 'chapters') {
|
|
||||||
// Handle logging of chapters separately because the object is large
|
|
||||||
const chaptersRemoved = libraryItemExpanded.media.chapters.filter((ch) => !updatedMedia.chapters.some((uch) => uch.id === ch.id))
|
|
||||||
if (chaptersRemoved.length) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" chapters removed: ${chaptersRemoved.map((ch) => ch.title).join(', ')}`)
|
|
||||||
}
|
|
||||||
const chaptersAdded = updatedMedia.chapters.filter((uch) => !libraryItemExpanded.media.chapters.some((ch) => ch.id === uch.id))
|
|
||||||
if (chaptersAdded.length) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" chapters added: ${chaptersAdded.map((ch) => ch.title).join(', ')}`)
|
|
||||||
}
|
|
||||||
if (!chaptersRemoved.length && !chaptersAdded.length) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" chapters updated`)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
Logger.debug(util.format(`[LibraryItem] "${libraryItemExpanded.media.title}" ${libraryItemExpanded.mediaType}.${key} updated from %j to %j`, existingValue, updatedMedia[key]))
|
|
||||||
}
|
|
||||||
|
|
||||||
hasMediaUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (hasMediaUpdates && updatedMedia) {
|
|
||||||
await libraryItemExpanded.media.update(updatedMedia)
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
const updatedLibraryItem = this.getFromOld(oldLibraryItem)
|
|
||||||
let hasLibraryItemUpdates = false
|
|
||||||
for (const key in updatedLibraryItem) {
|
|
||||||
let existingValue = libraryItemExpanded[key]
|
|
||||||
if (existingValue instanceof Date) existingValue = existingValue.valueOf()
|
|
||||||
|
|
||||||
if (!areEquivalent(updatedLibraryItem[key], existingValue, true)) {
|
|
||||||
if (key === 'libraryFiles') {
|
|
||||||
// Handle logging of libraryFiles separately because the object is large (should be addressed when migrating off the old library item model)
|
|
||||||
const libraryFilesRemoved = libraryItemExpanded.libraryFiles.filter((lf) => !updatedLibraryItem.libraryFiles.some((ulf) => ulf.ino === lf.ino))
|
|
||||||
if (libraryFilesRemoved.length) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" library files removed: ${libraryFilesRemoved.map((lf) => lf.metadata.path).join(', ')}`)
|
|
||||||
}
|
|
||||||
const libraryFilesAdded = updatedLibraryItem.libraryFiles.filter((ulf) => !libraryItemExpanded.libraryFiles.some((lf) => lf.ino === ulf.ino))
|
|
||||||
if (libraryFilesAdded.length) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" library files added: ${libraryFilesAdded.map((lf) => lf.metadata.path).join(', ')}`)
|
|
||||||
}
|
|
||||||
if (!libraryFilesRemoved.length && !libraryFilesAdded.length) {
|
|
||||||
Logger.debug(`[LibraryItem] "${libraryItemExpanded.media.title}" library files updated`)
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
Logger.debug(util.format(`[LibraryItem] "${libraryItemExpanded.media.title}" ${key} updated from %j to %j`, existingValue, updatedLibraryItem[key]))
|
|
||||||
}
|
|
||||||
|
|
||||||
hasLibraryItemUpdates = true
|
|
||||||
if (key === 'updatedAt') {
|
|
||||||
libraryItemExpanded.changed('updatedAt', true)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (hasLibraryItemUpdates) {
|
|
||||||
await libraryItemExpanded.update(updatedLibraryItem)
|
|
||||||
Logger.info(`[LibraryItem] Library item "${libraryItemExpanded.id}" updated`)
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
static getFromOld(oldLibraryItem) {
|
|
||||||
const extraData = {}
|
|
||||||
if (oldLibraryItem.oldLibraryItemId) {
|
|
||||||
extraData.oldLibraryItemId = oldLibraryItem.oldLibraryItemId
|
|
||||||
}
|
|
||||||
return {
|
|
||||||
id: oldLibraryItem.id,
|
|
||||||
ino: oldLibraryItem.ino,
|
|
||||||
path: oldLibraryItem.path,
|
|
||||||
relPath: oldLibraryItem.relPath,
|
|
||||||
mediaId: oldLibraryItem.media.id,
|
|
||||||
mediaType: oldLibraryItem.mediaType,
|
|
||||||
isFile: !!oldLibraryItem.isFile,
|
|
||||||
isMissing: !!oldLibraryItem.isMissing,
|
|
||||||
isInvalid: !!oldLibraryItem.isInvalid,
|
|
||||||
mtime: oldLibraryItem.mtimeMs,
|
|
||||||
ctime: oldLibraryItem.ctimeMs,
|
|
||||||
updatedAt: oldLibraryItem.updatedAt,
|
|
||||||
birthtime: oldLibraryItem.birthtimeMs,
|
|
||||||
size: oldLibraryItem.size,
|
|
||||||
lastScan: oldLibraryItem.lastScan,
|
|
||||||
lastScanVersion: oldLibraryItem.scanVersion,
|
|
||||||
libraryId: oldLibraryItem.libraryId,
|
|
||||||
libraryFolderId: oldLibraryItem.folderId,
|
|
||||||
libraryFiles: oldLibraryItem.libraryFiles?.map((lf) => lf.toJSON()) || [],
|
|
||||||
extraData
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Remove library item by id
|
|
||||||
*
|
|
||||||
* @param {string} libraryItemId
|
|
||||||
* @returns {Promise<number>} The number of destroyed rows
|
|
||||||
*/
|
|
||||||
static removeById(libraryItemId) {
|
|
||||||
return this.destroy({
|
|
||||||
where: {
|
|
||||||
id: libraryItemId
|
|
||||||
},
|
|
||||||
individualHooks: true
|
|
||||||
})
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -498,16 +225,20 @@ class LibraryItem extends Model {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get old library item by id
|
*
|
||||||
* @param {string} libraryItemId
|
* @param {import('sequelize').WhereOptions} where
|
||||||
* @returns {oldLibraryItem}
|
* @param {import('sequelize').BindOrReplacements} [replacements]
|
||||||
|
* @param {import('sequelize').IncludeOptions} [include]
|
||||||
|
* @returns {Promise<LibraryItemExpanded>}
|
||||||
*/
|
*/
|
||||||
static async getOldById(libraryItemId) {
|
static async findOneExpanded(where, replacements = null, include = null) {
|
||||||
if (!libraryItemId) return null
|
const libraryItem = await this.findOne({
|
||||||
|
where,
|
||||||
const libraryItem = await this.findByPk(libraryItemId)
|
replacements,
|
||||||
|
include
|
||||||
|
})
|
||||||
if (!libraryItem) {
|
if (!libraryItem) {
|
||||||
Logger.error(`[LibraryItem] Library item not found with id "${libraryItemId}"`)
|
Logger.error(`[LibraryItem] Library item not found`)
|
||||||
return null
|
return null
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -531,7 +262,7 @@ class LibraryItem extends Model {
|
|||||||
{
|
{
|
||||||
model: this.sequelize.models.series,
|
model: this.sequelize.models.series,
|
||||||
through: {
|
through: {
|
||||||
attributes: ['sequence']
|
attributes: ['id', 'sequence']
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
@ -543,7 +274,7 @@ class LibraryItem extends Model {
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!libraryItem.media) return null
|
if (!libraryItem.media) return null
|
||||||
return this.getOldLibraryItem(libraryItem)
|
return libraryItem
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -551,7 +282,7 @@ class LibraryItem extends Model {
|
|||||||
* @param {import('./Library')} library
|
* @param {import('./Library')} library
|
||||||
* @param {import('./User')} user
|
* @param {import('./User')} user
|
||||||
* @param {object} options
|
* @param {object} options
|
||||||
* @returns {{ libraryItems:oldLibraryItem[], count:number }}
|
* @returns {{ libraryItems:Object[], count:number }}
|
||||||
*/
|
*/
|
||||||
static async getByFilterAndSort(library, user, options) {
|
static async getByFilterAndSort(library, user, options) {
|
||||||
let start = Date.now()
|
let start = Date.now()
|
||||||
@ -560,7 +291,7 @@ class LibraryItem extends Model {
|
|||||||
|
|
||||||
return {
|
return {
|
||||||
libraryItems: libraryItems.map((li) => {
|
libraryItems: libraryItems.map((li) => {
|
||||||
const oldLibraryItem = this.getOldLibraryItem(li).toJSONMinified()
|
const oldLibraryItem = li.toOldJSONMinified()
|
||||||
if (li.collapsedSeries) {
|
if (li.collapsedSeries) {
|
||||||
oldLibraryItem.collapsedSeries = li.collapsedSeries
|
oldLibraryItem.collapsedSeries = li.collapsedSeries
|
||||||
}
|
}
|
||||||
@ -605,17 +336,19 @@ class LibraryItem extends Model {
|
|||||||
// "Continue Listening" shelf
|
// "Continue Listening" shelf
|
||||||
const itemsInProgressPayload = await libraryFilters.getMediaItemsInProgress(library, user, include, limit, false)
|
const itemsInProgressPayload = await libraryFilters.getMediaItemsInProgress(library, user, include, limit, false)
|
||||||
if (itemsInProgressPayload.items.length) {
|
if (itemsInProgressPayload.items.length) {
|
||||||
const ebookOnlyItemsInProgress = itemsInProgressPayload.items.filter((li) => li.media.isEBookOnly)
|
const ebookOnlyItemsInProgress = itemsInProgressPayload.items.filter((li) => li.media.ebookFormat && !li.media.numTracks)
|
||||||
const audioOnlyItemsInProgress = itemsInProgressPayload.items.filter((li) => !li.media.isEBookOnly)
|
const audioItemsInProgress = itemsInProgressPayload.items.filter((li) => li.media.numTracks || li.mediaType === 'podcast')
|
||||||
|
|
||||||
shelves.push({
|
if (audioItemsInProgress.length) {
|
||||||
id: 'continue-listening',
|
shelves.push({
|
||||||
label: 'Continue Listening',
|
id: 'continue-listening',
|
||||||
labelStringKey: 'LabelContinueListening',
|
label: 'Continue Listening',
|
||||||
type: library.isPodcast ? 'episode' : 'book',
|
labelStringKey: 'LabelContinueListening',
|
||||||
entities: audioOnlyItemsInProgress,
|
type: library.isPodcast ? 'episode' : 'book',
|
||||||
total: itemsInProgressPayload.count
|
entities: audioItemsInProgress,
|
||||||
})
|
total: itemsInProgressPayload.count
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
if (ebookOnlyItemsInProgress.length) {
|
if (ebookOnlyItemsInProgress.length) {
|
||||||
// "Continue Reading" shelf
|
// "Continue Reading" shelf
|
||||||
@ -714,17 +447,19 @@ class LibraryItem extends Model {
|
|||||||
// "Listen Again" shelf
|
// "Listen Again" shelf
|
||||||
const mediaFinishedPayload = await libraryFilters.getMediaFinished(library, user, include, limit)
|
const mediaFinishedPayload = await libraryFilters.getMediaFinished(library, user, include, limit)
|
||||||
if (mediaFinishedPayload.items.length) {
|
if (mediaFinishedPayload.items.length) {
|
||||||
const ebookOnlyItemsInProgress = mediaFinishedPayload.items.filter((li) => li.media.isEBookOnly)
|
const ebookOnlyItemsInProgress = mediaFinishedPayload.items.filter((li) => li.media.ebookFormat && !li.media.numTracks)
|
||||||
const audioOnlyItemsInProgress = mediaFinishedPayload.items.filter((li) => !li.media.isEBookOnly)
|
const audioItemsInProgress = mediaFinishedPayload.items.filter((li) => li.media.numTracks || li.mediaType === 'podcast')
|
||||||
|
|
||||||
shelves.push({
|
if (audioItemsInProgress.length) {
|
||||||
id: 'listen-again',
|
shelves.push({
|
||||||
label: 'Listen Again',
|
id: 'listen-again',
|
||||||
labelStringKey: 'LabelListenAgain',
|
label: 'Listen Again',
|
||||||
type: library.isPodcast ? 'episode' : 'book',
|
labelStringKey: 'LabelListenAgain',
|
||||||
entities: audioOnlyItemsInProgress,
|
type: library.isPodcast ? 'episode' : 'book',
|
||||||
total: mediaFinishedPayload.count
|
entities: audioItemsInProgress,
|
||||||
})
|
total: mediaFinishedPayload.count
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
// "Read Again" shelf
|
// "Read Again" shelf
|
||||||
if (ebookOnlyItemsInProgress.length) {
|
if (ebookOnlyItemsInProgress.length) {
|
||||||
@ -766,21 +501,11 @@ class LibraryItem extends Model {
|
|||||||
* Get book library items for author, optional use user permissions
|
* Get book library items for author, optional use user permissions
|
||||||
* @param {import('./Author')} author
|
* @param {import('./Author')} author
|
||||||
* @param {import('./User')} user
|
* @param {import('./User')} user
|
||||||
* @returns {Promise<oldLibraryItem[]>}
|
* @returns {Promise<LibraryItemExpanded[]>}
|
||||||
*/
|
*/
|
||||||
static async getForAuthor(author, user = null) {
|
static async getForAuthor(author, user = null) {
|
||||||
const { libraryItems } = await libraryFilters.getLibraryItemsForAuthor(author, user, undefined, undefined)
|
const { libraryItems } = await libraryFilters.getLibraryItemsForAuthor(author, user, undefined, undefined)
|
||||||
return libraryItems.map((li) => this.getOldLibraryItem(li))
|
return libraryItems
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get book library items in a collection
|
|
||||||
* @param {oldCollection} collection
|
|
||||||
* @returns {Promise<oldLibraryItem[]>}
|
|
||||||
*/
|
|
||||||
static async getForCollection(collection) {
|
|
||||||
const libraryItems = await libraryFilters.getLibraryItemsForCollection(collection)
|
|
||||||
return libraryItems.map((li) => this.getOldLibraryItem(li))
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -792,52 +517,6 @@ class LibraryItem extends Model {
|
|||||||
return (await this.count({ where: { id: libraryItemId } })) > 0
|
return (await this.count({ where: { id: libraryItemId } })) > 0
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
* @param {import('sequelize').WhereOptions} where
|
|
||||||
* @param {import('sequelize').BindOrReplacements} replacements
|
|
||||||
* @returns {Object} oldLibraryItem
|
|
||||||
*/
|
|
||||||
static async findOneOld(where, replacements = {}) {
|
|
||||||
const libraryItem = await this.findOne({
|
|
||||||
where,
|
|
||||||
replacements,
|
|
||||||
include: [
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.book,
|
|
||||||
include: [
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.author,
|
|
||||||
through: {
|
|
||||||
attributes: []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.series,
|
|
||||||
through: {
|
|
||||||
attributes: ['sequence']
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
},
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.podcast,
|
|
||||||
include: [
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.podcastEpisode
|
|
||||||
}
|
|
||||||
]
|
|
||||||
}
|
|
||||||
],
|
|
||||||
order: [
|
|
||||||
[this.sequelize.models.book, this.sequelize.models.author, this.sequelize.models.bookAuthor, 'createdAt', 'ASC'],
|
|
||||||
[this.sequelize.models.book, this.sequelize.models.series, 'bookSeries', 'createdAt', 'ASC']
|
|
||||||
]
|
|
||||||
})
|
|
||||||
if (!libraryItem) return null
|
|
||||||
return this.getOldLibraryItem(libraryItem)
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @param {string} libraryItemId
|
* @param {string} libraryItemId
|
||||||
@ -865,54 +544,6 @@ class LibraryItem extends Model {
|
|||||||
return libraryItem.media.coverPath
|
return libraryItem.media.coverPath
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
* @param {import('sequelize').FindOptions} options
|
|
||||||
* @returns {Promise<Book|Podcast>}
|
|
||||||
*/
|
|
||||||
getMedia(options) {
|
|
||||||
if (!this.mediaType) return Promise.resolve(null)
|
|
||||||
const mixinMethodName = `get${this.sequelize.uppercaseFirst(this.mediaType)}`
|
|
||||||
return this[mixinMethodName](options)
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
*
|
|
||||||
* @returns {Promise<Book|Podcast>}
|
|
||||||
*/
|
|
||||||
getMediaExpanded() {
|
|
||||||
if (this.mediaType === 'podcast') {
|
|
||||||
return this.getMedia({
|
|
||||||
include: [
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.podcastEpisode
|
|
||||||
}
|
|
||||||
]
|
|
||||||
})
|
|
||||||
} else {
|
|
||||||
return this.getMedia({
|
|
||||||
include: [
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.author,
|
|
||||||
through: {
|
|
||||||
attributes: []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.series,
|
|
||||||
through: {
|
|
||||||
attributes: ['sequence']
|
|
||||||
}
|
|
||||||
}
|
|
||||||
],
|
|
||||||
order: [
|
|
||||||
[this.sequelize.models.author, this.sequelize.models.bookAuthor, 'createdAt', 'ASC'],
|
|
||||||
[this.sequelize.models.series, 'bookSeries', 'createdAt', 'ASC']
|
|
||||||
]
|
|
||||||
})
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
*
|
*
|
||||||
* @returns {Promise}
|
* @returns {Promise}
|
||||||
@ -1009,7 +640,7 @@ class LibraryItem extends Model {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Logger.debug(`Success saving abmetadata to "${metadataFilePath}"`)
|
Logger.debug(`[LibraryItem] Saved metadata for "${this.media.title}" file to "${metadataFilePath}"`)
|
||||||
|
|
||||||
return metadataLibraryFile
|
return metadataLibraryFile
|
||||||
})
|
})
|
||||||
@ -1131,6 +762,64 @@ class LibraryItem extends Model {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get isBook() {
|
||||||
|
return this.mediaType === 'book'
|
||||||
|
}
|
||||||
|
get isPodcast() {
|
||||||
|
return this.mediaType === 'podcast'
|
||||||
|
}
|
||||||
|
get hasAudioTracks() {
|
||||||
|
return this.media.hasAudioTracks()
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('sequelize').FindOptions} options
|
||||||
|
* @returns {Promise<Book|Podcast>}
|
||||||
|
*/
|
||||||
|
getMedia(options) {
|
||||||
|
if (!this.mediaType) return Promise.resolve(null)
|
||||||
|
const mixinMethodName = `get${this.sequelize.uppercaseFirst(this.mediaType)}`
|
||||||
|
return this[mixinMethodName](options)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @returns {Promise<Book|Podcast>}
|
||||||
|
*/
|
||||||
|
getMediaExpanded() {
|
||||||
|
if (this.mediaType === 'podcast') {
|
||||||
|
return this.getMedia({
|
||||||
|
include: [
|
||||||
|
{
|
||||||
|
model: this.sequelize.models.podcastEpisode
|
||||||
|
}
|
||||||
|
]
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
return this.getMedia({
|
||||||
|
include: [
|
||||||
|
{
|
||||||
|
model: this.sequelize.models.author,
|
||||||
|
through: {
|
||||||
|
attributes: []
|
||||||
|
}
|
||||||
|
},
|
||||||
|
{
|
||||||
|
model: this.sequelize.models.series,
|
||||||
|
through: {
|
||||||
|
attributes: ['sequence']
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
order: [
|
||||||
|
[this.sequelize.models.author, this.sequelize.models.bookAuthor, 'createdAt', 'ASC'],
|
||||||
|
[this.sequelize.models.series, 'bookSeries', 'createdAt', 'ASC']
|
||||||
|
]
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Check if book or podcast library item has audio tracks
|
* Check if book or podcast library item has audio tracks
|
||||||
* Requires expanded library item
|
* Requires expanded library item
|
||||||
@ -1142,12 +831,149 @@ class LibraryItem extends Model {
|
|||||||
Logger.error(`[LibraryItem] hasAudioTracks: Library item "${this.id}" does not have media`)
|
Logger.error(`[LibraryItem] hasAudioTracks: Library item "${this.id}" does not have media`)
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
if (this.mediaType === 'book') {
|
if (this.isBook) {
|
||||||
return this.media.audioFiles?.length > 0
|
return this.media.audioFiles?.length > 0
|
||||||
} else {
|
} else {
|
||||||
return this.media.podcastEpisodes?.length > 0
|
return this.media.podcastEpisodes?.length > 0
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {string} ino
|
||||||
|
* @returns {import('./Book').AudioFileObject}
|
||||||
|
*/
|
||||||
|
getAudioFileWithIno(ino) {
|
||||||
|
if (!this.media) {
|
||||||
|
Logger.error(`[LibraryItem] getAudioFileWithIno: Library item "${this.id}" does not have media`)
|
||||||
|
return null
|
||||||
|
}
|
||||||
|
if (this.isBook) {
|
||||||
|
return this.media.audioFiles.find((af) => af.ino === ino)
|
||||||
|
} else {
|
||||||
|
return this.media.podcastEpisodes.find((pe) => pe.audioFile?.ino === ino)?.audioFile
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the track list to be used in client audio players
|
||||||
|
* AudioTrack is the AudioFile with startOffset and contentUrl
|
||||||
|
* Podcasts must have an episodeId to get the track list
|
||||||
|
*
|
||||||
|
* @param {string} [episodeId]
|
||||||
|
* @returns {import('./Book').AudioTrack[]}
|
||||||
|
*/
|
||||||
|
getTrackList(episodeId) {
|
||||||
|
if (!this.media) {
|
||||||
|
Logger.error(`[LibraryItem] getTrackList: Library item "${this.id}" does not have media`)
|
||||||
|
return []
|
||||||
|
}
|
||||||
|
return this.media.getTracklist(this.id, episodeId)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {string} ino
|
||||||
|
* @returns {LibraryFile}
|
||||||
|
*/
|
||||||
|
getLibraryFileWithIno(ino) {
|
||||||
|
const libraryFile = this.libraryFiles.find((lf) => lf.ino === ino)
|
||||||
|
if (!libraryFile) return null
|
||||||
|
return new LibraryFile(libraryFile)
|
||||||
|
}
|
||||||
|
|
||||||
|
getLibraryFiles() {
|
||||||
|
return this.libraryFiles.map((lf) => new LibraryFile(lf))
|
||||||
|
}
|
||||||
|
|
||||||
|
getLibraryFilesJson() {
|
||||||
|
return this.libraryFiles.map((lf) => new LibraryFile(lf).toJSON())
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSON() {
|
||||||
|
if (!this.media) {
|
||||||
|
throw new Error(`[LibraryItem] Cannot convert to old JSON without media for library item "${this.id}"`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
ino: this.ino,
|
||||||
|
oldLibraryItemId: this.extraData?.oldLibraryItemId || null,
|
||||||
|
libraryId: this.libraryId,
|
||||||
|
folderId: this.libraryFolderId,
|
||||||
|
path: this.path,
|
||||||
|
relPath: this.relPath,
|
||||||
|
isFile: this.isFile,
|
||||||
|
mtimeMs: this.mtime?.valueOf(),
|
||||||
|
ctimeMs: this.ctime?.valueOf(),
|
||||||
|
birthtimeMs: this.birthtime?.valueOf(),
|
||||||
|
addedAt: this.createdAt.valueOf(),
|
||||||
|
updatedAt: this.updatedAt.valueOf(),
|
||||||
|
lastScan: this.lastScan?.valueOf(),
|
||||||
|
scanVersion: this.lastScanVersion,
|
||||||
|
isMissing: !!this.isMissing,
|
||||||
|
isInvalid: !!this.isInvalid,
|
||||||
|
mediaType: this.mediaType,
|
||||||
|
media: this.media.toOldJSON(this.id),
|
||||||
|
// LibraryFile JSON includes a fileType property that may not be saved in libraryFiles column in the database
|
||||||
|
libraryFiles: this.getLibraryFilesJson()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSONMinified() {
|
||||||
|
if (!this.media) {
|
||||||
|
throw new Error(`[LibraryItem] Cannot convert to old JSON without media for library item "${this.id}"`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
ino: this.ino,
|
||||||
|
oldLibraryItemId: this.extraData?.oldLibraryItemId || null,
|
||||||
|
libraryId: this.libraryId,
|
||||||
|
folderId: this.libraryFolderId,
|
||||||
|
path: this.path,
|
||||||
|
relPath: this.relPath,
|
||||||
|
isFile: this.isFile,
|
||||||
|
mtimeMs: this.mtime?.valueOf(),
|
||||||
|
ctimeMs: this.ctime?.valueOf(),
|
||||||
|
birthtimeMs: this.birthtime?.valueOf(),
|
||||||
|
addedAt: this.createdAt.valueOf(),
|
||||||
|
updatedAt: this.updatedAt.valueOf(),
|
||||||
|
isMissing: !!this.isMissing,
|
||||||
|
isInvalid: !!this.isInvalid,
|
||||||
|
mediaType: this.mediaType,
|
||||||
|
media: this.media.toOldJSONMinified(),
|
||||||
|
numFiles: this.libraryFiles.length,
|
||||||
|
size: this.size
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSONExpanded() {
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
ino: this.ino,
|
||||||
|
oldLibraryItemId: this.extraData?.oldLibraryItemId || null,
|
||||||
|
libraryId: this.libraryId,
|
||||||
|
folderId: this.libraryFolderId,
|
||||||
|
path: this.path,
|
||||||
|
relPath: this.relPath,
|
||||||
|
isFile: this.isFile,
|
||||||
|
mtimeMs: this.mtime?.valueOf(),
|
||||||
|
ctimeMs: this.ctime?.valueOf(),
|
||||||
|
birthtimeMs: this.birthtime?.valueOf(),
|
||||||
|
addedAt: this.createdAt.valueOf(),
|
||||||
|
updatedAt: this.updatedAt.valueOf(),
|
||||||
|
lastScan: this.lastScan?.valueOf(),
|
||||||
|
scanVersion: this.lastScanVersion,
|
||||||
|
isMissing: !!this.isMissing,
|
||||||
|
isInvalid: !!this.isInvalid,
|
||||||
|
mediaType: this.mediaType,
|
||||||
|
media: this.media.toOldJSONExpanded(this.id),
|
||||||
|
// LibraryFile JSON includes a fileType property that may not be saved in libraryFiles column in the database
|
||||||
|
libraryFiles: this.getLibraryFilesJson(),
|
||||||
|
size: this.size
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = LibraryItem
|
module.exports = LibraryItem
|
||||||
|
@ -76,42 +76,23 @@ class MediaItemShare extends Model {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
* Expanded book that includes library settings
|
||||||
*
|
*
|
||||||
* @param {string} mediaItemId
|
* @param {string} mediaItemId
|
||||||
* @param {string} mediaItemType
|
* @param {string} mediaItemType
|
||||||
* @returns {Promise<import('../objects/LibraryItem')>}
|
* @returns {Promise<import('./LibraryItem').LibraryItemExpanded>}
|
||||||
*/
|
*/
|
||||||
static async getMediaItemsOldLibraryItem(mediaItemId, mediaItemType) {
|
static async getMediaItemsLibraryItem(mediaItemId, mediaItemType) {
|
||||||
|
/** @type {typeof import('./LibraryItem')} */
|
||||||
|
const libraryItemModel = this.sequelize.models.libraryItem
|
||||||
|
|
||||||
if (mediaItemType === 'book') {
|
if (mediaItemType === 'book') {
|
||||||
const book = await this.sequelize.models.book.findByPk(mediaItemId, {
|
const libraryItem = await libraryItemModel.findOneExpanded({ mediaId: mediaItemId }, null, {
|
||||||
include: [
|
model: this.sequelize.models.library,
|
||||||
{
|
attributes: ['settings']
|
||||||
model: this.sequelize.models.author,
|
|
||||||
through: {
|
|
||||||
attributes: []
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.series,
|
|
||||||
through: {
|
|
||||||
attributes: ['sequence']
|
|
||||||
}
|
|
||||||
},
|
|
||||||
{
|
|
||||||
model: this.sequelize.models.libraryItem,
|
|
||||||
include: {
|
|
||||||
model: this.sequelize.models.library,
|
|
||||||
attributes: ['settings']
|
|
||||||
}
|
|
||||||
}
|
|
||||||
]
|
|
||||||
})
|
})
|
||||||
const libraryItem = book.libraryItem
|
|
||||||
libraryItem.media = book
|
return libraryItem
|
||||||
delete book.libraryItem
|
|
||||||
const oldLibraryItem = this.sequelize.models.libraryItem.getOldLibraryItem(libraryItem)
|
|
||||||
oldLibraryItem.librarySettings = libraryItem.library.settings
|
|
||||||
return oldLibraryItem
|
|
||||||
}
|
}
|
||||||
return null
|
return null
|
||||||
}
|
}
|
||||||
|
@ -36,33 +36,6 @@ class MediaProgress extends Model {
|
|||||||
this.createdAt
|
this.createdAt
|
||||||
}
|
}
|
||||||
|
|
||||||
static upsertFromOld(oldMediaProgress) {
|
|
||||||
const mediaProgress = this.getFromOld(oldMediaProgress)
|
|
||||||
return this.upsert(mediaProgress)
|
|
||||||
}
|
|
||||||
|
|
||||||
static getFromOld(oldMediaProgress) {
|
|
||||||
return {
|
|
||||||
id: oldMediaProgress.id,
|
|
||||||
userId: oldMediaProgress.userId,
|
|
||||||
mediaItemId: oldMediaProgress.mediaItemId,
|
|
||||||
mediaItemType: oldMediaProgress.mediaItemType,
|
|
||||||
duration: oldMediaProgress.duration,
|
|
||||||
currentTime: oldMediaProgress.currentTime,
|
|
||||||
ebookLocation: oldMediaProgress.ebookLocation || null,
|
|
||||||
ebookProgress: oldMediaProgress.ebookProgress || null,
|
|
||||||
isFinished: !!oldMediaProgress.isFinished,
|
|
||||||
hideFromContinueListening: !!oldMediaProgress.hideFromContinueListening,
|
|
||||||
finishedAt: oldMediaProgress.finishedAt,
|
|
||||||
createdAt: oldMediaProgress.startedAt || oldMediaProgress.lastUpdate,
|
|
||||||
updatedAt: oldMediaProgress.lastUpdate,
|
|
||||||
extraData: {
|
|
||||||
libraryItemId: oldMediaProgress.libraryItemId,
|
|
||||||
progress: oldMediaProgress.progress
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static removeById(mediaProgressId) {
|
static removeById(mediaProgressId) {
|
||||||
return this.destroy({
|
return this.destroy({
|
||||||
where: {
|
where: {
|
||||||
@ -71,12 +44,6 @@ class MediaProgress extends Model {
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
getMediaItem(options) {
|
|
||||||
if (!this.mediaItemType) return Promise.resolve(null)
|
|
||||||
const mixinMethodName = `get${this.sequelize.uppercaseFirst(this.mediaItemType)}`
|
|
||||||
return this[mixinMethodName](options)
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize model
|
* Initialize model
|
||||||
*
|
*
|
||||||
@ -162,6 +129,12 @@ class MediaProgress extends Model {
|
|||||||
MediaProgress.belongsTo(user)
|
MediaProgress.belongsTo(user)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
getMediaItem(options) {
|
||||||
|
if (!this.mediaItemType) return Promise.resolve(null)
|
||||||
|
const mixinMethodName = `get${this.sequelize.uppercaseFirst(this.mediaItemType)}`
|
||||||
|
return this[mixinMethodName](options)
|
||||||
|
}
|
||||||
|
|
||||||
getOldMediaProgress() {
|
getOldMediaProgress() {
|
||||||
const isPodcastEpisode = this.mediaItemType === 'podcastEpisode'
|
const isPodcastEpisode = this.mediaItemType === 'podcastEpisode'
|
||||||
|
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
const { DataTypes, Model, Op } = require('sequelize')
|
const { DataTypes, Model, Op } = require('sequelize')
|
||||||
const Logger = require('../Logger')
|
const Logger = require('../Logger')
|
||||||
|
const SocketAuthority = require('../SocketAuthority')
|
||||||
|
|
||||||
class Playlist extends Model {
|
class Playlist extends Model {
|
||||||
constructor(values, options) {
|
constructor(values, options) {
|
||||||
@ -163,6 +164,49 @@ class Playlist extends Model {
|
|||||||
return playlists
|
return playlists
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes media items and re-orders playlists
|
||||||
|
*
|
||||||
|
* @param {string[]} mediaItemIds
|
||||||
|
*/
|
||||||
|
static async removeMediaItemsFromPlaylists(mediaItemIds) {
|
||||||
|
if (!mediaItemIds?.length) return
|
||||||
|
|
||||||
|
const playlistsWithItem = await this.getPlaylistsForMediaItemIds(mediaItemIds)
|
||||||
|
|
||||||
|
if (!playlistsWithItem.length) return
|
||||||
|
|
||||||
|
for (const playlist of playlistsWithItem) {
|
||||||
|
let numMediaItems = playlist.playlistMediaItems.length
|
||||||
|
|
||||||
|
let order = 1
|
||||||
|
// Remove items in playlist and re-order
|
||||||
|
for (const playlistMediaItem of playlist.playlistMediaItems) {
|
||||||
|
if (mediaItemIds.includes(playlistMediaItem.mediaItemId)) {
|
||||||
|
await playlistMediaItem.destroy()
|
||||||
|
numMediaItems--
|
||||||
|
} else {
|
||||||
|
if (playlistMediaItem.order !== order) {
|
||||||
|
playlistMediaItem.update({
|
||||||
|
order
|
||||||
|
})
|
||||||
|
}
|
||||||
|
order++
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// If playlist is now empty then remove it
|
||||||
|
const jsonExpanded = await playlist.getOldJsonExpanded()
|
||||||
|
if (!numMediaItems) {
|
||||||
|
Logger.info(`[ApiRouter] Playlist "${playlist.name}" has no more items - removing it`)
|
||||||
|
await playlist.destroy()
|
||||||
|
SocketAuthority.clientEmitter(playlist.userId, 'playlist_removed', jsonExpanded)
|
||||||
|
} else {
|
||||||
|
SocketAuthority.clientEmitter(playlist.userId, 'playlist_updated', jsonExpanded)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize model
|
* Initialize model
|
||||||
* @param {import('../Database').sequelize} sequelize
|
* @param {import('../Database').sequelize} sequelize
|
||||||
@ -313,7 +357,7 @@ class Playlist extends Model {
|
|||||||
libraryItem.media = pmi.mediaItem
|
libraryItem.media = pmi.mediaItem
|
||||||
return {
|
return {
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItem: this.sequelize.models.libraryItem.getOldLibraryItem(libraryItem).toJSONExpanded()
|
libraryItem: libraryItem.toOldJSONExpanded()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -324,7 +368,7 @@ class Playlist extends Model {
|
|||||||
episodeId: pmi.mediaItemId,
|
episodeId: pmi.mediaItemId,
|
||||||
episode: pmi.mediaItem.toOldJSONExpanded(libraryItem.id),
|
episode: pmi.mediaItem.toOldJSONExpanded(libraryItem.id),
|
||||||
libraryItemId: libraryItem.id,
|
libraryItemId: libraryItem.id,
|
||||||
libraryItem: this.sequelize.models.libraryItem.getOldLibraryItem(libraryItem).toJSONMinified()
|
libraryItem: libraryItem.toOldJSONMinified()
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
@ -1,4 +1,6 @@
|
|||||||
const { DataTypes, Model } = require('sequelize')
|
const { DataTypes, Model } = require('sequelize')
|
||||||
|
const { getTitlePrefixAtEnd, getTitleIgnorePrefix } = require('../utils')
|
||||||
|
const Logger = require('../Logger')
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef PodcastExpandedProperties
|
* @typedef PodcastExpandedProperties
|
||||||
@ -47,6 +49,8 @@ class Podcast extends Model {
|
|||||||
this.lastEpisodeCheck
|
this.lastEpisodeCheck
|
||||||
/** @type {number} */
|
/** @type {number} */
|
||||||
this.maxEpisodesToKeep
|
this.maxEpisodesToKeep
|
||||||
|
/** @type {number} */
|
||||||
|
this.maxNewEpisodesToDownload
|
||||||
/** @type {string} */
|
/** @type {string} */
|
||||||
this.coverPath
|
this.coverPath
|
||||||
/** @type {string[]} */
|
/** @type {string[]} */
|
||||||
@ -57,85 +61,48 @@ class Podcast extends Model {
|
|||||||
this.createdAt
|
this.createdAt
|
||||||
/** @type {Date} */
|
/** @type {Date} */
|
||||||
this.updatedAt
|
this.updatedAt
|
||||||
|
|
||||||
|
/** @type {import('./PodcastEpisode')[]} */
|
||||||
|
this.podcastEpisodes
|
||||||
}
|
}
|
||||||
|
|
||||||
static getOldPodcast(libraryItemExpanded) {
|
/**
|
||||||
const podcastExpanded = libraryItemExpanded.media
|
* Payload from the /api/podcasts POST endpoint
|
||||||
const podcastEpisodes = podcastExpanded.podcastEpisodes?.map((ep) => ep.getOldPodcastEpisode(libraryItemExpanded.id).toJSON()).sort((a, b) => a.index - b.index)
|
*
|
||||||
return {
|
* @param {Object} payload
|
||||||
id: podcastExpanded.id,
|
* @param {import('sequelize').Transaction} transaction
|
||||||
libraryItemId: libraryItemExpanded.id,
|
*/
|
||||||
metadata: {
|
static async createFromRequest(payload, transaction) {
|
||||||
title: podcastExpanded.title,
|
const title = typeof payload.metadata.title === 'string' ? payload.metadata.title : null
|
||||||
author: podcastExpanded.author,
|
const autoDownloadSchedule = typeof payload.autoDownloadSchedule === 'string' ? payload.autoDownloadSchedule : null
|
||||||
description: podcastExpanded.description,
|
const genres = Array.isArray(payload.metadata.genres) && payload.metadata.genres.every((g) => typeof g === 'string' && g.length) ? payload.metadata.genres : []
|
||||||
releaseDate: podcastExpanded.releaseDate,
|
const tags = Array.isArray(payload.tags) && payload.tags.every((t) => typeof t === 'string' && t.length) ? payload.tags : []
|
||||||
genres: podcastExpanded.genres,
|
|
||||||
feedUrl: podcastExpanded.feedURL,
|
return this.create(
|
||||||
imageUrl: podcastExpanded.imageURL,
|
{
|
||||||
itunesPageUrl: podcastExpanded.itunesPageURL,
|
title,
|
||||||
itunesId: podcastExpanded.itunesId,
|
titleIgnorePrefix: getTitleIgnorePrefix(title),
|
||||||
itunesArtistId: podcastExpanded.itunesArtistId,
|
author: typeof payload.metadata.author === 'string' ? payload.metadata.author : null,
|
||||||
explicit: podcastExpanded.explicit,
|
releaseDate: typeof payload.metadata.releaseDate === 'string' ? payload.metadata.releaseDate : null,
|
||||||
language: podcastExpanded.language,
|
feedURL: typeof payload.metadata.feedUrl === 'string' ? payload.metadata.feedUrl : null,
|
||||||
type: podcastExpanded.podcastType
|
imageURL: typeof payload.metadata.imageUrl === 'string' ? payload.metadata.imageUrl : null,
|
||||||
|
description: typeof payload.metadata.description === 'string' ? payload.metadata.description : null,
|
||||||
|
itunesPageURL: typeof payload.metadata.itunesPageUrl === 'string' ? payload.metadata.itunesPageUrl : null,
|
||||||
|
itunesId: typeof payload.metadata.itunesId === 'string' ? payload.metadata.itunesId : null,
|
||||||
|
itunesArtistId: typeof payload.metadata.itunesArtistId === 'string' ? payload.metadata.itunesArtistId : null,
|
||||||
|
language: typeof payload.metadata.language === 'string' ? payload.metadata.language : null,
|
||||||
|
podcastType: typeof payload.metadata.type === 'string' ? payload.metadata.type : null,
|
||||||
|
explicit: !!payload.metadata.explicit,
|
||||||
|
autoDownloadEpisodes: !!payload.autoDownloadEpisodes,
|
||||||
|
autoDownloadSchedule: autoDownloadSchedule || global.ServerSettings.podcastEpisodeSchedule,
|
||||||
|
lastEpisodeCheck: new Date(),
|
||||||
|
maxEpisodesToKeep: 0,
|
||||||
|
maxNewEpisodesToDownload: 3,
|
||||||
|
tags,
|
||||||
|
genres
|
||||||
},
|
},
|
||||||
coverPath: podcastExpanded.coverPath,
|
{ transaction }
|
||||||
tags: podcastExpanded.tags,
|
)
|
||||||
episodes: podcastEpisodes || [],
|
|
||||||
autoDownloadEpisodes: podcastExpanded.autoDownloadEpisodes,
|
|
||||||
autoDownloadSchedule: podcastExpanded.autoDownloadSchedule,
|
|
||||||
lastEpisodeCheck: podcastExpanded.lastEpisodeCheck?.valueOf() || null,
|
|
||||||
maxEpisodesToKeep: podcastExpanded.maxEpisodesToKeep,
|
|
||||||
maxNewEpisodesToDownload: podcastExpanded.maxNewEpisodesToDownload
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
static getFromOld(oldPodcast) {
|
|
||||||
const oldPodcastMetadata = oldPodcast.metadata
|
|
||||||
return {
|
|
||||||
id: oldPodcast.id,
|
|
||||||
title: oldPodcastMetadata.title,
|
|
||||||
titleIgnorePrefix: oldPodcastMetadata.titleIgnorePrefix,
|
|
||||||
author: oldPodcastMetadata.author,
|
|
||||||
releaseDate: oldPodcastMetadata.releaseDate,
|
|
||||||
feedURL: oldPodcastMetadata.feedUrl,
|
|
||||||
imageURL: oldPodcastMetadata.imageUrl,
|
|
||||||
description: oldPodcastMetadata.description,
|
|
||||||
itunesPageURL: oldPodcastMetadata.itunesPageUrl,
|
|
||||||
itunesId: oldPodcastMetadata.itunesId,
|
|
||||||
itunesArtistId: oldPodcastMetadata.itunesArtistId,
|
|
||||||
language: oldPodcastMetadata.language,
|
|
||||||
podcastType: oldPodcastMetadata.type,
|
|
||||||
explicit: !!oldPodcastMetadata.explicit,
|
|
||||||
autoDownloadEpisodes: !!oldPodcast.autoDownloadEpisodes,
|
|
||||||
autoDownloadSchedule: oldPodcast.autoDownloadSchedule,
|
|
||||||
lastEpisodeCheck: oldPodcast.lastEpisodeCheck,
|
|
||||||
maxEpisodesToKeep: oldPodcast.maxEpisodesToKeep,
|
|
||||||
maxNewEpisodesToDownload: oldPodcast.maxNewEpisodesToDownload,
|
|
||||||
coverPath: oldPodcast.coverPath,
|
|
||||||
tags: oldPodcast.tags,
|
|
||||||
genres: oldPodcastMetadata.genres
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
getAbsMetadataJson() {
|
|
||||||
return {
|
|
||||||
tags: this.tags || [],
|
|
||||||
title: this.title,
|
|
||||||
author: this.author,
|
|
||||||
description: this.description,
|
|
||||||
releaseDate: this.releaseDate,
|
|
||||||
genres: this.genres || [],
|
|
||||||
feedURL: this.feedURL,
|
|
||||||
imageURL: this.imageURL,
|
|
||||||
itunesPageURL: this.itunesPageURL,
|
|
||||||
itunesId: this.itunesId,
|
|
||||||
itunesArtistId: this.itunesArtistId,
|
|
||||||
language: this.language,
|
|
||||||
explicit: !!this.explicit,
|
|
||||||
podcastType: this.podcastType
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -179,6 +146,311 @@ class Podcast extends Model {
|
|||||||
}
|
}
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get hasMediaFiles() {
|
||||||
|
return !!this.podcastEpisodes?.length
|
||||||
|
}
|
||||||
|
|
||||||
|
get hasAudioTracks() {
|
||||||
|
return this.hasMediaFiles
|
||||||
|
}
|
||||||
|
|
||||||
|
get size() {
|
||||||
|
if (!this.podcastEpisodes?.length) return 0
|
||||||
|
return this.podcastEpisodes.reduce((total, episode) => total + episode.size, 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
getAbsMetadataJson() {
|
||||||
|
return {
|
||||||
|
tags: this.tags || [],
|
||||||
|
title: this.title,
|
||||||
|
author: this.author,
|
||||||
|
description: this.description,
|
||||||
|
releaseDate: this.releaseDate,
|
||||||
|
genres: this.genres || [],
|
||||||
|
feedURL: this.feedURL,
|
||||||
|
imageURL: this.imageURL,
|
||||||
|
itunesPageURL: this.itunesPageURL,
|
||||||
|
itunesId: this.itunesId,
|
||||||
|
itunesArtistId: this.itunesArtistId,
|
||||||
|
language: this.language,
|
||||||
|
explicit: !!this.explicit,
|
||||||
|
podcastType: this.podcastType
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {Object} payload - Old podcast object
|
||||||
|
* @returns {Promise<boolean>}
|
||||||
|
*/
|
||||||
|
async updateFromRequest(payload) {
|
||||||
|
if (!payload) return false
|
||||||
|
|
||||||
|
let hasUpdates = false
|
||||||
|
|
||||||
|
if (payload.metadata) {
|
||||||
|
const stringKeys = ['title', 'author', 'releaseDate', 'feedUrl', 'imageUrl', 'description', 'itunesPageUrl', 'itunesId', 'itunesArtistId', 'language', 'type']
|
||||||
|
stringKeys.forEach((key) => {
|
||||||
|
let newKey = key
|
||||||
|
if (key === 'type') {
|
||||||
|
newKey = 'podcastType'
|
||||||
|
} else if (key === 'feedUrl') {
|
||||||
|
newKey = 'feedURL'
|
||||||
|
} else if (key === 'imageUrl') {
|
||||||
|
newKey = 'imageURL'
|
||||||
|
} else if (key === 'itunesPageUrl') {
|
||||||
|
newKey = 'itunesPageURL'
|
||||||
|
}
|
||||||
|
if (typeof payload.metadata[key] === 'string' && payload.metadata[key] !== this[newKey]) {
|
||||||
|
this[newKey] = payload.metadata[key]
|
||||||
|
if (key === 'title') {
|
||||||
|
this.titleIgnorePrefix = getTitleIgnorePrefix(this.title)
|
||||||
|
}
|
||||||
|
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
if (payload.metadata.explicit !== undefined && payload.metadata.explicit !== this.explicit) {
|
||||||
|
this.explicit = !!payload.metadata.explicit
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Array.isArray(payload.metadata.genres) && !payload.metadata.genres.some((item) => typeof item !== 'string') && JSON.stringify(this.genres) !== JSON.stringify(payload.metadata.genres)) {
|
||||||
|
this.genres = payload.metadata.genres
|
||||||
|
this.changed('genres', true)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (Array.isArray(payload.tags) && !payload.tags.some((item) => typeof item !== 'string') && JSON.stringify(this.tags) !== JSON.stringify(payload.tags)) {
|
||||||
|
this.tags = payload.tags
|
||||||
|
this.changed('tags', true)
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
|
||||||
|
if (payload.autoDownloadEpisodes !== undefined && payload.autoDownloadEpisodes !== this.autoDownloadEpisodes) {
|
||||||
|
this.autoDownloadEpisodes = !!payload.autoDownloadEpisodes
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
if (typeof payload.autoDownloadSchedule === 'string' && payload.autoDownloadSchedule !== this.autoDownloadSchedule) {
|
||||||
|
this.autoDownloadSchedule = payload.autoDownloadSchedule
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
if (typeof payload.lastEpisodeCheck === 'number' && payload.lastEpisodeCheck !== this.lastEpisodeCheck?.valueOf()) {
|
||||||
|
this.lastEpisodeCheck = payload.lastEpisodeCheck
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
|
||||||
|
const numberKeys = ['maxEpisodesToKeep', 'maxNewEpisodesToDownload']
|
||||||
|
numberKeys.forEach((key) => {
|
||||||
|
if (typeof payload[key] === 'number' && payload[key] !== this[key]) {
|
||||||
|
this[key] = payload[key]
|
||||||
|
hasUpdates = true
|
||||||
|
}
|
||||||
|
})
|
||||||
|
|
||||||
|
if (hasUpdates) {
|
||||||
|
Logger.debug(`[Podcast] changed keys:`, this.changed())
|
||||||
|
await this.save()
|
||||||
|
}
|
||||||
|
|
||||||
|
return hasUpdates
|
||||||
|
}
|
||||||
|
|
||||||
|
checkCanDirectPlay(supportedMimeTypes, episodeId) {
|
||||||
|
if (!Array.isArray(supportedMimeTypes)) {
|
||||||
|
Logger.error(`[Podcast] checkCanDirectPlay: supportedMimeTypes is not an array`, supportedMimeTypes)
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
const episode = this.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
|
if (!episode) {
|
||||||
|
Logger.error(`[Podcast] checkCanDirectPlay: episode not found`, episodeId)
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
return supportedMimeTypes.includes(episode.audioFile.mimeType)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Get the track list to be used in client audio players
|
||||||
|
* AudioTrack is the AudioFile with startOffset and contentUrl
|
||||||
|
* Podcast episodes only have one track
|
||||||
|
*
|
||||||
|
* @param {string} libraryItemId
|
||||||
|
* @param {string} episodeId
|
||||||
|
* @returns {import('./Book').AudioTrack[]}
|
||||||
|
*/
|
||||||
|
getTracklist(libraryItemId, episodeId) {
|
||||||
|
const episode = this.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
|
if (!episode) {
|
||||||
|
Logger.error(`[Podcast] getTracklist: episode not found`, episodeId)
|
||||||
|
return []
|
||||||
|
}
|
||||||
|
|
||||||
|
const audioTrack = episode.getAudioTrack(libraryItemId)
|
||||||
|
return [audioTrack]
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {string} episodeId
|
||||||
|
* @returns {import('./PodcastEpisode').ChapterObject[]}
|
||||||
|
*/
|
||||||
|
getChapters(episodeId) {
|
||||||
|
const episode = this.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
|
if (!episode) {
|
||||||
|
Logger.error(`[Podcast] getChapters: episode not found`, episodeId)
|
||||||
|
return []
|
||||||
|
}
|
||||||
|
|
||||||
|
return structuredClone(episode.chapters) || []
|
||||||
|
}
|
||||||
|
|
||||||
|
getPlaybackTitle(episodeId) {
|
||||||
|
const episode = this.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
|
if (!episode) {
|
||||||
|
Logger.error(`[Podcast] getPlaybackTitle: episode not found`, episodeId)
|
||||||
|
return ''
|
||||||
|
}
|
||||||
|
|
||||||
|
return episode.title
|
||||||
|
}
|
||||||
|
|
||||||
|
getPlaybackAuthor() {
|
||||||
|
return this.author
|
||||||
|
}
|
||||||
|
|
||||||
|
getPlaybackDuration(episodeId) {
|
||||||
|
const episode = this.podcastEpisodes.find((ep) => ep.id === episodeId)
|
||||||
|
if (!episode) {
|
||||||
|
Logger.error(`[Podcast] getPlaybackDuration: episode not found`, episodeId)
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
return episode.duration
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @returns {number} - Unix timestamp
|
||||||
|
*/
|
||||||
|
getLatestEpisodePublishedAt() {
|
||||||
|
return this.podcastEpisodes.reduce((latest, episode) => {
|
||||||
|
if (episode.publishedAt?.valueOf() > latest) {
|
||||||
|
return episode.publishedAt.valueOf()
|
||||||
|
}
|
||||||
|
return latest
|
||||||
|
}, 0)
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Used for checking if an rss feed episode is already in the podcast
|
||||||
|
*
|
||||||
|
* @param {import('../utils/podcastUtils').RssPodcastEpisode} feedEpisode - object from rss feed
|
||||||
|
* @returns {boolean}
|
||||||
|
*/
|
||||||
|
checkHasEpisodeByFeedEpisode(feedEpisode) {
|
||||||
|
const guid = feedEpisode.guid
|
||||||
|
const url = feedEpisode.enclosure.url
|
||||||
|
return this.podcastEpisodes.some((ep) => ep.checkMatchesGuidOrEnclosureUrl(guid, url))
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Old model kept metadata in a separate object
|
||||||
|
*/
|
||||||
|
oldMetadataToJSON() {
|
||||||
|
return {
|
||||||
|
title: this.title,
|
||||||
|
author: this.author,
|
||||||
|
description: this.description,
|
||||||
|
releaseDate: this.releaseDate,
|
||||||
|
genres: [...(this.genres || [])],
|
||||||
|
feedUrl: this.feedURL,
|
||||||
|
imageUrl: this.imageURL,
|
||||||
|
itunesPageUrl: this.itunesPageURL,
|
||||||
|
itunesId: this.itunesId,
|
||||||
|
itunesArtistId: this.itunesArtistId,
|
||||||
|
explicit: this.explicit,
|
||||||
|
language: this.language,
|
||||||
|
type: this.podcastType
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
oldMetadataToJSONExpanded() {
|
||||||
|
const oldMetadataJSON = this.oldMetadataToJSON()
|
||||||
|
oldMetadataJSON.titleIgnorePrefix = getTitlePrefixAtEnd(this.title)
|
||||||
|
return oldMetadataJSON
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* The old model stored episodes with the podcast object
|
||||||
|
*
|
||||||
|
* @param {string} libraryItemId
|
||||||
|
*/
|
||||||
|
toOldJSON(libraryItemId) {
|
||||||
|
if (!libraryItemId) {
|
||||||
|
throw new Error(`[Podcast] Cannot convert to old JSON because libraryItemId is not provided`)
|
||||||
|
}
|
||||||
|
if (!this.podcastEpisodes) {
|
||||||
|
throw new Error(`[Podcast] Cannot convert to old JSON because episodes are not provided`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
libraryItemId: libraryItemId,
|
||||||
|
metadata: this.oldMetadataToJSON(),
|
||||||
|
coverPath: this.coverPath,
|
||||||
|
tags: [...(this.tags || [])],
|
||||||
|
episodes: this.podcastEpisodes.map((episode) => episode.toOldJSON(libraryItemId)),
|
||||||
|
autoDownloadEpisodes: this.autoDownloadEpisodes,
|
||||||
|
autoDownloadSchedule: this.autoDownloadSchedule,
|
||||||
|
lastEpisodeCheck: this.lastEpisodeCheck?.valueOf() || null,
|
||||||
|
maxEpisodesToKeep: this.maxEpisodesToKeep,
|
||||||
|
maxNewEpisodesToDownload: this.maxNewEpisodesToDownload
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSONMinified() {
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
// Minified metadata and expanded metadata are the same
|
||||||
|
metadata: this.oldMetadataToJSONExpanded(),
|
||||||
|
coverPath: this.coverPath,
|
||||||
|
tags: [...(this.tags || [])],
|
||||||
|
numEpisodes: this.podcastEpisodes?.length || 0,
|
||||||
|
autoDownloadEpisodes: this.autoDownloadEpisodes,
|
||||||
|
autoDownloadSchedule: this.autoDownloadSchedule,
|
||||||
|
lastEpisodeCheck: this.lastEpisodeCheck?.valueOf() || null,
|
||||||
|
maxEpisodesToKeep: this.maxEpisodesToKeep,
|
||||||
|
maxNewEpisodesToDownload: this.maxNewEpisodesToDownload,
|
||||||
|
size: this.size
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
toOldJSONExpanded(libraryItemId) {
|
||||||
|
if (!libraryItemId) {
|
||||||
|
throw new Error(`[Podcast] Cannot convert to old JSON because libraryItemId is not provided`)
|
||||||
|
}
|
||||||
|
if (!this.podcastEpisodes) {
|
||||||
|
throw new Error(`[Podcast] Cannot convert to old JSON because episodes are not provided`)
|
||||||
|
}
|
||||||
|
|
||||||
|
return {
|
||||||
|
id: this.id,
|
||||||
|
libraryItemId: libraryItemId,
|
||||||
|
metadata: this.oldMetadataToJSONExpanded(),
|
||||||
|
coverPath: this.coverPath,
|
||||||
|
tags: [...(this.tags || [])],
|
||||||
|
episodes: this.podcastEpisodes.map((e) => e.toOldJSONExpanded(libraryItemId)),
|
||||||
|
autoDownloadEpisodes: this.autoDownloadEpisodes,
|
||||||
|
autoDownloadSchedule: this.autoDownloadSchedule,
|
||||||
|
lastEpisodeCheck: this.lastEpisodeCheck?.valueOf() || null,
|
||||||
|
maxEpisodesToKeep: this.maxEpisodesToKeep,
|
||||||
|
maxNewEpisodesToDownload: this.maxNewEpisodesToDownload,
|
||||||
|
size: this.size
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
module.exports = Podcast
|
module.exports = Podcast
|
||||||
|
@ -1,5 +1,4 @@
|
|||||||
const { DataTypes, Model } = require('sequelize')
|
const { DataTypes, Model } = require('sequelize')
|
||||||
const oldPodcastEpisode = require('../objects/entities/PodcastEpisode')
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @typedef ChapterObject
|
* @typedef ChapterObject
|
||||||
@ -54,75 +53,39 @@ class PodcastEpisode extends Model {
|
|||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @param {string} libraryItemId
|
*
|
||||||
* @returns {oldPodcastEpisode}
|
* @param {import('../utils/podcastUtils').RssPodcastEpisode} rssPodcastEpisode
|
||||||
|
* @param {string} podcastId
|
||||||
|
* @param {import('../objects/files/AudioFile')} audioFile
|
||||||
*/
|
*/
|
||||||
getOldPodcastEpisode(libraryItemId = null) {
|
static async createFromRssPodcastEpisode(rssPodcastEpisode, podcastId, audioFile) {
|
||||||
let enclosure = null
|
const podcastEpisode = {
|
||||||
if (this.enclosureURL) {
|
index: null,
|
||||||
enclosure = {
|
season: rssPodcastEpisode.season,
|
||||||
url: this.enclosureURL,
|
episode: rssPodcastEpisode.episode,
|
||||||
type: this.enclosureType,
|
episodeType: rssPodcastEpisode.episodeType,
|
||||||
length: this.enclosureSize !== null ? String(this.enclosureSize) : null
|
title: rssPodcastEpisode.title,
|
||||||
}
|
subtitle: rssPodcastEpisode.subtitle,
|
||||||
|
description: rssPodcastEpisode.description,
|
||||||
|
pubDate: rssPodcastEpisode.pubDate,
|
||||||
|
enclosureURL: rssPodcastEpisode.enclosure?.url || null,
|
||||||
|
enclosureSize: rssPodcastEpisode.enclosure?.length || null,
|
||||||
|
enclosureType: rssPodcastEpisode.enclosure?.type || null,
|
||||||
|
publishedAt: rssPodcastEpisode.publishedAt,
|
||||||
|
podcastId,
|
||||||
|
audioFile: audioFile.toJSON(),
|
||||||
|
chapters: [],
|
||||||
|
extraData: {}
|
||||||
|
}
|
||||||
|
if (rssPodcastEpisode.guid) {
|
||||||
|
podcastEpisode.extraData.guid = rssPodcastEpisode.guid
|
||||||
|
}
|
||||||
|
if (audioFile.chapters?.length) {
|
||||||
|
podcastEpisode.chapters = audioFile.chapters.map((ch) => ({ ...ch }))
|
||||||
}
|
}
|
||||||
return new oldPodcastEpisode({
|
|
||||||
libraryItemId: libraryItemId || null,
|
|
||||||
podcastId: this.podcastId,
|
|
||||||
id: this.id,
|
|
||||||
oldEpisodeId: this.extraData?.oldEpisodeId || null,
|
|
||||||
index: this.index,
|
|
||||||
season: this.season,
|
|
||||||
episode: this.episode,
|
|
||||||
episodeType: this.episodeType,
|
|
||||||
title: this.title,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
description: this.description,
|
|
||||||
enclosure,
|
|
||||||
guid: this.extraData?.guid || null,
|
|
||||||
pubDate: this.pubDate,
|
|
||||||
chapters: this.chapters,
|
|
||||||
audioFile: this.audioFile,
|
|
||||||
publishedAt: this.publishedAt?.valueOf() || null,
|
|
||||||
addedAt: this.createdAt.valueOf(),
|
|
||||||
updatedAt: this.updatedAt.valueOf()
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
static createFromOld(oldEpisode) {
|
|
||||||
const podcastEpisode = this.getFromOld(oldEpisode)
|
|
||||||
return this.create(podcastEpisode)
|
return this.create(podcastEpisode)
|
||||||
}
|
}
|
||||||
|
|
||||||
static getFromOld(oldEpisode) {
|
|
||||||
const extraData = {}
|
|
||||||
if (oldEpisode.oldEpisodeId) {
|
|
||||||
extraData.oldEpisodeId = oldEpisode.oldEpisodeId
|
|
||||||
}
|
|
||||||
if (oldEpisode.guid) {
|
|
||||||
extraData.guid = oldEpisode.guid
|
|
||||||
}
|
|
||||||
return {
|
|
||||||
id: oldEpisode.id,
|
|
||||||
index: oldEpisode.index,
|
|
||||||
season: oldEpisode.season,
|
|
||||||
episode: oldEpisode.episode,
|
|
||||||
episodeType: oldEpisode.episodeType,
|
|
||||||
title: oldEpisode.title,
|
|
||||||
subtitle: oldEpisode.subtitle,
|
|
||||||
description: oldEpisode.description,
|
|
||||||
pubDate: oldEpisode.pubDate,
|
|
||||||
enclosureURL: oldEpisode.enclosure?.url || null,
|
|
||||||
enclosureSize: oldEpisode.enclosure?.length || null,
|
|
||||||
enclosureType: oldEpisode.enclosure?.type || null,
|
|
||||||
publishedAt: oldEpisode.publishedAt,
|
|
||||||
podcastId: oldEpisode.podcastId,
|
|
||||||
audioFile: oldEpisode.audioFile?.toJSON() || null,
|
|
||||||
chapters: oldEpisode.chapters,
|
|
||||||
extraData
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize model
|
* Initialize model
|
||||||
* @param {import('../Database').sequelize} sequelize
|
* @param {import('../Database').sequelize} sequelize
|
||||||
@ -171,20 +134,50 @@ class PodcastEpisode extends Model {
|
|||||||
PodcastEpisode.belongsTo(podcast)
|
PodcastEpisode.belongsTo(podcast)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get size() {
|
||||||
|
return this.audioFile?.metadata.size || 0
|
||||||
|
}
|
||||||
|
|
||||||
|
get duration() {
|
||||||
|
return this.audioFile?.duration || 0
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* AudioTrack object used in old model
|
* Used for matching the episode with an episode in the RSS feed
|
||||||
*
|
*
|
||||||
* @returns {import('./Book').AudioFileObject|null}
|
* @param {string} guid
|
||||||
|
* @param {string} enclosureURL
|
||||||
|
* @returns {boolean}
|
||||||
*/
|
*/
|
||||||
get track() {
|
checkMatchesGuidOrEnclosureUrl(guid, enclosureURL) {
|
||||||
if (!this.audioFile) return null
|
if (this.extraData?.guid && this.extraData.guid === guid) {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
if (this.enclosureURL && this.enclosureURL === enclosureURL) {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
return false
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Used in client players
|
||||||
|
*
|
||||||
|
* @param {string} libraryItemId
|
||||||
|
* @returns {import('./Book').AudioTrack}
|
||||||
|
*/
|
||||||
|
getAudioTrack(libraryItemId) {
|
||||||
const track = structuredClone(this.audioFile)
|
const track = structuredClone(this.audioFile)
|
||||||
track.startOffset = 0
|
track.startOffset = 0
|
||||||
track.title = this.audioFile.metadata.title
|
track.title = this.audioFile.metadata.filename
|
||||||
|
track.contentUrl = `${global.RouterBasePath}/api/items/${libraryItemId}/file/${track.ino}`
|
||||||
return track
|
return track
|
||||||
}
|
}
|
||||||
|
|
||||||
toOldJSON(libraryItemId) {
|
toOldJSON(libraryItemId) {
|
||||||
|
if (!libraryItemId) {
|
||||||
|
throw new Error(`[PodcastEpisode] Cannot convert to old JSON because libraryItemId is not provided`)
|
||||||
|
}
|
||||||
|
|
||||||
let enclosure = null
|
let enclosure = null
|
||||||
if (this.enclosureURL) {
|
if (this.enclosureURL) {
|
||||||
enclosure = {
|
enclosure = {
|
||||||
@ -209,8 +202,8 @@ class PodcastEpisode extends Model {
|
|||||||
enclosure,
|
enclosure,
|
||||||
guid: this.extraData?.guid || null,
|
guid: this.extraData?.guid || null,
|
||||||
pubDate: this.pubDate,
|
pubDate: this.pubDate,
|
||||||
chapters: this.chapters?.map((ch) => ({ ...ch })) || [],
|
chapters: structuredClone(this.chapters),
|
||||||
audioFile: this.audioFile || null,
|
audioFile: structuredClone(this.audioFile),
|
||||||
publishedAt: this.publishedAt?.valueOf() || null,
|
publishedAt: this.publishedAt?.valueOf() || null,
|
||||||
addedAt: this.createdAt.valueOf(),
|
addedAt: this.createdAt.valueOf(),
|
||||||
updatedAt: this.updatedAt.valueOf()
|
updatedAt: this.updatedAt.valueOf()
|
||||||
@ -220,9 +213,9 @@ class PodcastEpisode extends Model {
|
|||||||
toOldJSONExpanded(libraryItemId) {
|
toOldJSONExpanded(libraryItemId) {
|
||||||
const json = this.toOldJSON(libraryItemId)
|
const json = this.toOldJSON(libraryItemId)
|
||||||
|
|
||||||
json.audioTrack = this.track
|
json.audioTrack = this.getAudioTrack(libraryItemId)
|
||||||
json.size = this.audioFile?.metadata.size || 0
|
json.size = this.size
|
||||||
json.duration = this.audioFile?.duration || 0
|
json.duration = this.duration
|
||||||
|
|
||||||
return json
|
return json
|
||||||
}
|
}
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
const { DataTypes, Model, where, fn, col, literal } = require('sequelize')
|
const { DataTypes, Model, where, fn, col, literal } = require('sequelize')
|
||||||
|
|
||||||
const { getTitlePrefixAtEnd } = require('../utils/index')
|
const { getTitlePrefixAtEnd, getTitleIgnorePrefix } = require('../utils/index')
|
||||||
|
|
||||||
class Series extends Model {
|
class Series extends Model {
|
||||||
constructor(values, options) {
|
constructor(values, options) {
|
||||||
@ -66,6 +66,22 @@ class Series extends Model {
|
|||||||
return series
|
return series
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {string} seriesName
|
||||||
|
* @param {string} libraryId
|
||||||
|
* @returns {Promise<Series>}
|
||||||
|
*/
|
||||||
|
static async findOrCreateByNameAndLibrary(seriesName, libraryId) {
|
||||||
|
const series = await this.getByNameAndLibrary(seriesName, libraryId)
|
||||||
|
if (series) return series
|
||||||
|
return this.create({
|
||||||
|
name: seriesName,
|
||||||
|
nameIgnorePrefix: getTitleIgnorePrefix(seriesName),
|
||||||
|
libraryId
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize model
|
* Initialize model
|
||||||
* @param {import('../Database').sequelize} sequelize
|
* @param {import('../Database').sequelize} sequelize
|
||||||
|
@ -563,9 +563,8 @@ class User extends Model {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Check user can access library item
|
* Check user can access library item
|
||||||
* TODO: Currently supports both old and new library item models
|
|
||||||
*
|
*
|
||||||
* @param {import('../objects/LibraryItem')|import('./LibraryItem')} libraryItem
|
* @param {import('./LibraryItem')} libraryItem
|
||||||
* @returns {boolean}
|
* @returns {boolean}
|
||||||
*/
|
*/
|
||||||
checkCanAccessLibraryItem(libraryItem) {
|
checkCanAccessLibraryItem(libraryItem) {
|
||||||
|
@ -1,346 +0,0 @@
|
|||||||
const uuidv4 = require('uuid').v4
|
|
||||||
const fs = require('../libs/fsExtra')
|
|
||||||
const Path = require('path')
|
|
||||||
const Logger = require('../Logger')
|
|
||||||
const LibraryFile = require('./files/LibraryFile')
|
|
||||||
const Book = require('./mediaTypes/Book')
|
|
||||||
const Podcast = require('./mediaTypes/Podcast')
|
|
||||||
const { areEquivalent, copyValue } = require('../utils/index')
|
|
||||||
const { filePathToPOSIX, getFileTimestampsWithIno } = require('../utils/fileUtils')
|
|
||||||
|
|
||||||
class LibraryItem {
|
|
||||||
constructor(libraryItem = null) {
|
|
||||||
this.id = null
|
|
||||||
this.ino = null // Inode
|
|
||||||
this.oldLibraryItemId = null
|
|
||||||
|
|
||||||
this.libraryId = null
|
|
||||||
this.folderId = null
|
|
||||||
|
|
||||||
this.path = null
|
|
||||||
this.relPath = null
|
|
||||||
this.isFile = false
|
|
||||||
this.mtimeMs = null
|
|
||||||
this.ctimeMs = null
|
|
||||||
this.birthtimeMs = null
|
|
||||||
this.addedAt = null
|
|
||||||
this.updatedAt = null
|
|
||||||
this.lastScan = null
|
|
||||||
this.scanVersion = null
|
|
||||||
|
|
||||||
// Was scanned and no longer exists
|
|
||||||
this.isMissing = false
|
|
||||||
// Was scanned and no longer has media files
|
|
||||||
this.isInvalid = false
|
|
||||||
|
|
||||||
this.mediaType = null
|
|
||||||
this.media = null
|
|
||||||
|
|
||||||
/** @type {LibraryFile[]} */
|
|
||||||
this.libraryFiles = []
|
|
||||||
|
|
||||||
if (libraryItem) {
|
|
||||||
this.construct(libraryItem)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Temporary attributes
|
|
||||||
this.isSavingMetadata = false
|
|
||||||
}
|
|
||||||
|
|
||||||
construct(libraryItem) {
|
|
||||||
this.id = libraryItem.id
|
|
||||||
this.ino = libraryItem.ino || null
|
|
||||||
this.oldLibraryItemId = libraryItem.oldLibraryItemId
|
|
||||||
this.libraryId = libraryItem.libraryId
|
|
||||||
this.folderId = libraryItem.folderId
|
|
||||||
this.path = libraryItem.path
|
|
||||||
this.relPath = libraryItem.relPath
|
|
||||||
this.isFile = !!libraryItem.isFile
|
|
||||||
this.mtimeMs = libraryItem.mtimeMs || 0
|
|
||||||
this.ctimeMs = libraryItem.ctimeMs || 0
|
|
||||||
this.birthtimeMs = libraryItem.birthtimeMs || 0
|
|
||||||
this.addedAt = libraryItem.addedAt
|
|
||||||
this.updatedAt = libraryItem.updatedAt || this.addedAt
|
|
||||||
this.lastScan = libraryItem.lastScan || null
|
|
||||||
this.scanVersion = libraryItem.scanVersion || null
|
|
||||||
|
|
||||||
this.isMissing = !!libraryItem.isMissing
|
|
||||||
this.isInvalid = !!libraryItem.isInvalid
|
|
||||||
|
|
||||||
this.mediaType = libraryItem.mediaType
|
|
||||||
if (this.mediaType === 'book') {
|
|
||||||
this.media = new Book(libraryItem.media)
|
|
||||||
} else if (this.mediaType === 'podcast') {
|
|
||||||
this.media = new Podcast(libraryItem.media)
|
|
||||||
}
|
|
||||||
this.media.libraryItemId = this.id
|
|
||||||
|
|
||||||
this.libraryFiles = libraryItem.libraryFiles.map((f) => new LibraryFile(f))
|
|
||||||
|
|
||||||
// Migration for v2.2.23 to set ebook library files as supplementary
|
|
||||||
if (this.isBook && this.media.ebookFile) {
|
|
||||||
for (const libraryFile of this.libraryFiles) {
|
|
||||||
if (libraryFile.isEBookFile && libraryFile.isSupplementary === null) {
|
|
||||||
libraryFile.isSupplementary = this.media.ebookFile.ino !== libraryFile.ino
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSON() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
ino: this.ino,
|
|
||||||
oldLibraryItemId: this.oldLibraryItemId,
|
|
||||||
libraryId: this.libraryId,
|
|
||||||
folderId: this.folderId,
|
|
||||||
path: this.path,
|
|
||||||
relPath: this.relPath,
|
|
||||||
isFile: this.isFile,
|
|
||||||
mtimeMs: this.mtimeMs,
|
|
||||||
ctimeMs: this.ctimeMs,
|
|
||||||
birthtimeMs: this.birthtimeMs,
|
|
||||||
addedAt: this.addedAt,
|
|
||||||
updatedAt: this.updatedAt,
|
|
||||||
lastScan: this.lastScan,
|
|
||||||
scanVersion: this.scanVersion,
|
|
||||||
isMissing: !!this.isMissing,
|
|
||||||
isInvalid: !!this.isInvalid,
|
|
||||||
mediaType: this.mediaType,
|
|
||||||
media: this.media.toJSON(),
|
|
||||||
libraryFiles: this.libraryFiles.map((f) => f.toJSON())
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONMinified() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
ino: this.ino,
|
|
||||||
oldLibraryItemId: this.oldLibraryItemId,
|
|
||||||
libraryId: this.libraryId,
|
|
||||||
folderId: this.folderId,
|
|
||||||
path: this.path,
|
|
||||||
relPath: this.relPath,
|
|
||||||
isFile: this.isFile,
|
|
||||||
mtimeMs: this.mtimeMs,
|
|
||||||
ctimeMs: this.ctimeMs,
|
|
||||||
birthtimeMs: this.birthtimeMs,
|
|
||||||
addedAt: this.addedAt,
|
|
||||||
updatedAt: this.updatedAt,
|
|
||||||
isMissing: !!this.isMissing,
|
|
||||||
isInvalid: !!this.isInvalid,
|
|
||||||
mediaType: this.mediaType,
|
|
||||||
media: this.media.toJSONMinified(),
|
|
||||||
numFiles: this.libraryFiles.length,
|
|
||||||
size: this.size
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Adds additional helpful fields like media duration, tracks, etc.
|
|
||||||
toJSONExpanded() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
ino: this.ino,
|
|
||||||
oldLibraryItemId: this.oldLibraryItemId,
|
|
||||||
libraryId: this.libraryId,
|
|
||||||
folderId: this.folderId,
|
|
||||||
path: this.path,
|
|
||||||
relPath: this.relPath,
|
|
||||||
isFile: this.isFile,
|
|
||||||
mtimeMs: this.mtimeMs,
|
|
||||||
ctimeMs: this.ctimeMs,
|
|
||||||
birthtimeMs: this.birthtimeMs,
|
|
||||||
addedAt: this.addedAt,
|
|
||||||
updatedAt: this.updatedAt,
|
|
||||||
lastScan: this.lastScan,
|
|
||||||
scanVersion: this.scanVersion,
|
|
||||||
isMissing: !!this.isMissing,
|
|
||||||
isInvalid: !!this.isInvalid,
|
|
||||||
mediaType: this.mediaType,
|
|
||||||
media: this.media.toJSONExpanded(),
|
|
||||||
libraryFiles: this.libraryFiles.map((f) => f.toJSON()),
|
|
||||||
size: this.size
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
get isPodcast() {
|
|
||||||
return this.mediaType === 'podcast'
|
|
||||||
}
|
|
||||||
get isBook() {
|
|
||||||
return this.mediaType === 'book'
|
|
||||||
}
|
|
||||||
get size() {
|
|
||||||
let total = 0
|
|
||||||
this.libraryFiles.forEach((lf) => (total += lf.metadata.size))
|
|
||||||
return total
|
|
||||||
}
|
|
||||||
get hasAudioFiles() {
|
|
||||||
return this.libraryFiles.some((lf) => lf.fileType === 'audio')
|
|
||||||
}
|
|
||||||
get hasMediaEntities() {
|
|
||||||
return this.media.hasMediaEntities
|
|
||||||
}
|
|
||||||
|
|
||||||
// Data comes from scandir library item data
|
|
||||||
// TODO: Remove this function. Only used when creating a new podcast now
|
|
||||||
setData(libraryMediaType, payload) {
|
|
||||||
this.id = uuidv4()
|
|
||||||
this.mediaType = libraryMediaType
|
|
||||||
if (libraryMediaType === 'podcast') {
|
|
||||||
this.media = new Podcast()
|
|
||||||
} else {
|
|
||||||
Logger.error(`[LibraryItem] setData called with unsupported media type "${libraryMediaType}"`)
|
|
||||||
return
|
|
||||||
}
|
|
||||||
this.media.id = uuidv4()
|
|
||||||
this.media.libraryItemId = this.id
|
|
||||||
|
|
||||||
for (const key in payload) {
|
|
||||||
if (key === 'libraryFiles') {
|
|
||||||
this.libraryFiles = payload.libraryFiles.map((lf) => lf.clone())
|
|
||||||
|
|
||||||
// Set cover image
|
|
||||||
const imageFiles = this.libraryFiles.filter((lf) => lf.fileType === 'image')
|
|
||||||
const coverMatch = imageFiles.find((iFile) => /\/cover\.[^.\/]*$/.test(iFile.metadata.path))
|
|
||||||
if (coverMatch) {
|
|
||||||
this.media.coverPath = coverMatch.metadata.path
|
|
||||||
} else if (imageFiles.length) {
|
|
||||||
this.media.coverPath = imageFiles[0].metadata.path
|
|
||||||
}
|
|
||||||
} else if (this[key] !== undefined && key !== 'media') {
|
|
||||||
this[key] = payload[key]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (payload.media) {
|
|
||||||
this.media.setData(payload.media)
|
|
||||||
}
|
|
||||||
|
|
||||||
this.addedAt = Date.now()
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
}
|
|
||||||
|
|
||||||
update(payload) {
|
|
||||||
const json = this.toJSON()
|
|
||||||
let hasUpdates = false
|
|
||||||
for (const key in json) {
|
|
||||||
if (payload[key] !== undefined) {
|
|
||||||
if (key === 'media') {
|
|
||||||
if (this.media.update(payload[key])) {
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
} else if (!areEquivalent(payload[key], json[key])) {
|
|
||||||
this[key] = copyValue(payload[key])
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (hasUpdates) {
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
updateMediaCover(coverPath) {
|
|
||||||
this.media.updateCover(coverPath)
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
setMissing() {
|
|
||||||
this.isMissing = true
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
}
|
|
||||||
|
|
||||||
getDirectPlayTracklist(episodeId) {
|
|
||||||
return this.media.getDirectPlayTracklist(episodeId)
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Save metadata.json file
|
|
||||||
* TODO: Move to new LibraryItem model
|
|
||||||
* @returns {Promise<LibraryFile>} null if not saved
|
|
||||||
*/
|
|
||||||
async saveMetadata() {
|
|
||||||
if (this.isSavingMetadata || !global.MetadataPath) return null
|
|
||||||
|
|
||||||
this.isSavingMetadata = true
|
|
||||||
|
|
||||||
let metadataPath = Path.join(global.MetadataPath, 'items', this.id)
|
|
||||||
let storeMetadataWithItem = global.ServerSettings.storeMetadataWithItem
|
|
||||||
if (storeMetadataWithItem && !this.isFile) {
|
|
||||||
metadataPath = this.path
|
|
||||||
} else {
|
|
||||||
// Make sure metadata book dir exists
|
|
||||||
storeMetadataWithItem = false
|
|
||||||
await fs.ensureDir(metadataPath)
|
|
||||||
}
|
|
||||||
|
|
||||||
const metadataFilePath = Path.join(metadataPath, `metadata.${global.ServerSettings.metadataFileFormat}`)
|
|
||||||
|
|
||||||
return fs
|
|
||||||
.writeFile(metadataFilePath, JSON.stringify(this.media.toJSONForMetadataFile(), null, 2))
|
|
||||||
.then(async () => {
|
|
||||||
// Add metadata.json to libraryFiles array if it is new
|
|
||||||
let metadataLibraryFile = this.libraryFiles.find((lf) => lf.metadata.path === filePathToPOSIX(metadataFilePath))
|
|
||||||
if (storeMetadataWithItem) {
|
|
||||||
if (!metadataLibraryFile) {
|
|
||||||
metadataLibraryFile = new LibraryFile()
|
|
||||||
await metadataLibraryFile.setDataFromPath(metadataFilePath, `metadata.json`)
|
|
||||||
this.libraryFiles.push(metadataLibraryFile)
|
|
||||||
} else {
|
|
||||||
const fileTimestamps = await getFileTimestampsWithIno(metadataFilePath)
|
|
||||||
if (fileTimestamps) {
|
|
||||||
metadataLibraryFile.metadata.mtimeMs = fileTimestamps.mtimeMs
|
|
||||||
metadataLibraryFile.metadata.ctimeMs = fileTimestamps.ctimeMs
|
|
||||||
metadataLibraryFile.metadata.size = fileTimestamps.size
|
|
||||||
metadataLibraryFile.ino = fileTimestamps.ino
|
|
||||||
}
|
|
||||||
}
|
|
||||||
const libraryItemDirTimestamps = await getFileTimestampsWithIno(this.path)
|
|
||||||
if (libraryItemDirTimestamps) {
|
|
||||||
this.mtimeMs = libraryItemDirTimestamps.mtimeMs
|
|
||||||
this.ctimeMs = libraryItemDirTimestamps.ctimeMs
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Logger.debug(`[LibraryItem] Success saving abmetadata to "${metadataFilePath}"`)
|
|
||||||
|
|
||||||
return metadataLibraryFile
|
|
||||||
})
|
|
||||||
.catch((error) => {
|
|
||||||
Logger.error(`[LibraryItem] Failed to save json file at "${metadataFilePath}"`, error)
|
|
||||||
return null
|
|
||||||
})
|
|
||||||
.finally(() => {
|
|
||||||
this.isSavingMetadata = false
|
|
||||||
})
|
|
||||||
}
|
|
||||||
|
|
||||||
removeLibraryFile(ino) {
|
|
||||||
if (!ino) return false
|
|
||||||
const libraryFile = this.libraryFiles.find((lf) => lf.ino === ino)
|
|
||||||
if (libraryFile) {
|
|
||||||
this.libraryFiles = this.libraryFiles.filter((lf) => lf.ino !== ino)
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Set the EBookFile from a LibraryFile
|
|
||||||
* If null then ebookFile will be removed from the book
|
|
||||||
* all ebook library files that are not primary are marked as supplementary
|
|
||||||
*
|
|
||||||
* @param {LibraryFile} [libraryFile]
|
|
||||||
*/
|
|
||||||
setPrimaryEbook(ebookLibraryFile = null) {
|
|
||||||
const ebookLibraryFiles = this.libraryFiles.filter((lf) => lf.isEBookFile)
|
|
||||||
for (const libraryFile of ebookLibraryFiles) {
|
|
||||||
libraryFile.isSupplementary = ebookLibraryFile?.ino !== libraryFile.ino
|
|
||||||
}
|
|
||||||
this.media.setEbookFile(ebookLibraryFile)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
module.exports = LibraryItem
|
|
@ -1,8 +1,6 @@
|
|||||||
const date = require('../libs/dateAndTime')
|
const date = require('../libs/dateAndTime')
|
||||||
const uuidv4 = require('uuid').v4
|
const uuidv4 = require('uuid').v4
|
||||||
const serverVersion = require('../../package.json').version
|
const serverVersion = require('../../package.json').version
|
||||||
const BookMetadata = require('./metadata/BookMetadata')
|
|
||||||
const PodcastMetadata = require('./metadata/PodcastMetadata')
|
|
||||||
const DeviceInfo = require('./DeviceInfo')
|
const DeviceInfo = require('./DeviceInfo')
|
||||||
|
|
||||||
class PlaybackSession {
|
class PlaybackSession {
|
||||||
@ -60,7 +58,7 @@ class PlaybackSession {
|
|||||||
bookId: this.bookId,
|
bookId: this.bookId,
|
||||||
episodeId: this.episodeId,
|
episodeId: this.episodeId,
|
||||||
mediaType: this.mediaType,
|
mediaType: this.mediaType,
|
||||||
mediaMetadata: this.mediaMetadata?.toJSON() || null,
|
mediaMetadata: structuredClone(this.mediaMetadata),
|
||||||
chapters: (this.chapters || []).map((c) => ({ ...c })),
|
chapters: (this.chapters || []).map((c) => ({ ...c })),
|
||||||
displayTitle: this.displayTitle,
|
displayTitle: this.displayTitle,
|
||||||
displayAuthor: this.displayAuthor,
|
displayAuthor: this.displayAuthor,
|
||||||
@ -82,7 +80,7 @@ class PlaybackSession {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Session data to send to clients
|
* Session data to send to clients
|
||||||
* @param {Object} [libraryItem] - old library item
|
* @param {import('../models/LibraryItem')} [libraryItem]
|
||||||
* @returns
|
* @returns
|
||||||
*/
|
*/
|
||||||
toJSONForClient(libraryItem) {
|
toJSONForClient(libraryItem) {
|
||||||
@ -94,7 +92,7 @@ class PlaybackSession {
|
|||||||
bookId: this.bookId,
|
bookId: this.bookId,
|
||||||
episodeId: this.episodeId,
|
episodeId: this.episodeId,
|
||||||
mediaType: this.mediaType,
|
mediaType: this.mediaType,
|
||||||
mediaMetadata: this.mediaMetadata?.toJSON() || null,
|
mediaMetadata: structuredClone(this.mediaMetadata),
|
||||||
chapters: (this.chapters || []).map((c) => ({ ...c })),
|
chapters: (this.chapters || []).map((c) => ({ ...c })),
|
||||||
displayTitle: this.displayTitle,
|
displayTitle: this.displayTitle,
|
||||||
displayAuthor: this.displayAuthor,
|
displayAuthor: this.displayAuthor,
|
||||||
@ -112,7 +110,7 @@ class PlaybackSession {
|
|||||||
startedAt: this.startedAt,
|
startedAt: this.startedAt,
|
||||||
updatedAt: this.updatedAt,
|
updatedAt: this.updatedAt,
|
||||||
audioTracks: this.audioTracks.map((at) => at.toJSON?.() || { ...at }),
|
audioTracks: this.audioTracks.map((at) => at.toJSON?.() || { ...at }),
|
||||||
libraryItem: libraryItem?.toJSONExpanded() || null
|
libraryItem: libraryItem?.toOldJSONExpanded() || null
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -148,14 +146,7 @@ class PlaybackSession {
|
|||||||
this.serverVersion = session.serverVersion
|
this.serverVersion = session.serverVersion
|
||||||
this.chapters = session.chapters || []
|
this.chapters = session.chapters || []
|
||||||
|
|
||||||
this.mediaMetadata = null
|
this.mediaMetadata = session.mediaMetadata
|
||||||
if (session.mediaMetadata) {
|
|
||||||
if (this.mediaType === 'book') {
|
|
||||||
this.mediaMetadata = new BookMetadata(session.mediaMetadata)
|
|
||||||
} else if (this.mediaType === 'podcast') {
|
|
||||||
this.mediaMetadata = new PodcastMetadata(session.mediaMetadata)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
this.displayTitle = session.displayTitle || ''
|
this.displayTitle = session.displayTitle || ''
|
||||||
this.displayAuthor = session.displayAuthor || ''
|
this.displayAuthor = session.displayAuthor || ''
|
||||||
this.coverPath = session.coverPath
|
this.coverPath = session.coverPath
|
||||||
@ -205,6 +196,15 @@ class PlaybackSession {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @param {*} userId
|
||||||
|
* @param {*} mediaPlayer
|
||||||
|
* @param {*} deviceInfo
|
||||||
|
* @param {*} startTime
|
||||||
|
* @param {*} episodeId
|
||||||
|
*/
|
||||||
setData(libraryItem, userId, mediaPlayer, deviceInfo, startTime, episodeId = null) {
|
setData(libraryItem, userId, mediaPlayer, deviceInfo, startTime, episodeId = null) {
|
||||||
this.id = uuidv4()
|
this.id = uuidv4()
|
||||||
this.userId = userId
|
this.userId = userId
|
||||||
@ -213,13 +213,12 @@ class PlaybackSession {
|
|||||||
this.bookId = episodeId ? null : libraryItem.media.id
|
this.bookId = episodeId ? null : libraryItem.media.id
|
||||||
this.episodeId = episodeId
|
this.episodeId = episodeId
|
||||||
this.mediaType = libraryItem.mediaType
|
this.mediaType = libraryItem.mediaType
|
||||||
this.mediaMetadata = libraryItem.media.metadata.clone()
|
this.mediaMetadata = libraryItem.media.oldMetadataToJSON()
|
||||||
this.chapters = libraryItem.media.getChapters(episodeId)
|
this.chapters = libraryItem.media.getChapters(episodeId)
|
||||||
this.displayTitle = libraryItem.media.getPlaybackTitle(episodeId)
|
this.displayTitle = libraryItem.media.getPlaybackTitle(episodeId)
|
||||||
this.displayAuthor = libraryItem.media.getPlaybackAuthor()
|
this.displayAuthor = libraryItem.media.getPlaybackAuthor()
|
||||||
this.coverPath = libraryItem.media.coverPath
|
this.coverPath = libraryItem.media.coverPath
|
||||||
|
this.duration = libraryItem.media.getPlaybackDuration(episodeId)
|
||||||
this.setDuration(libraryItem, episodeId)
|
|
||||||
|
|
||||||
this.mediaPlayer = mediaPlayer
|
this.mediaPlayer = mediaPlayer
|
||||||
this.deviceInfo = deviceInfo || new DeviceInfo()
|
this.deviceInfo = deviceInfo || new DeviceInfo()
|
||||||
@ -235,14 +234,6 @@ class PlaybackSession {
|
|||||||
this.updatedAt = Date.now()
|
this.updatedAt = Date.now()
|
||||||
}
|
}
|
||||||
|
|
||||||
setDuration(libraryItem, episodeId) {
|
|
||||||
if (episodeId) {
|
|
||||||
this.duration = libraryItem.media.getEpisodeDuration(episodeId)
|
|
||||||
} else {
|
|
||||||
this.duration = libraryItem.media.duration
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
addListeningTime(timeListened) {
|
addListeningTime(timeListened) {
|
||||||
if (!timeListened || isNaN(timeListened)) return
|
if (!timeListened || isNaN(timeListened)) return
|
||||||
|
|
||||||
|
@ -6,8 +6,11 @@ const globals = require('../utils/globals')
|
|||||||
class PodcastEpisodeDownload {
|
class PodcastEpisodeDownload {
|
||||||
constructor() {
|
constructor() {
|
||||||
this.id = null
|
this.id = null
|
||||||
this.podcastEpisode = null
|
/** @type {import('../utils/podcastUtils').RssPodcastEpisode} */
|
||||||
|
this.rssPodcastEpisode = null
|
||||||
|
|
||||||
this.url = null
|
this.url = null
|
||||||
|
/** @type {import('../models/LibraryItem')} */
|
||||||
this.libraryItem = null
|
this.libraryItem = null
|
||||||
this.libraryId = null
|
this.libraryId = null
|
||||||
|
|
||||||
@ -15,7 +18,7 @@ class PodcastEpisodeDownload {
|
|||||||
this.isFinished = false
|
this.isFinished = false
|
||||||
this.failed = false
|
this.failed = false
|
||||||
|
|
||||||
this.appendEpisodeId = false
|
this.appendRandomId = false
|
||||||
|
|
||||||
this.startedAt = null
|
this.startedAt = null
|
||||||
this.createdAt = null
|
this.createdAt = null
|
||||||
@ -25,22 +28,22 @@ class PodcastEpisodeDownload {
|
|||||||
toJSONForClient() {
|
toJSONForClient() {
|
||||||
return {
|
return {
|
||||||
id: this.id,
|
id: this.id,
|
||||||
episodeDisplayTitle: this.podcastEpisode?.title ?? null,
|
episodeDisplayTitle: this.rssPodcastEpisode?.title ?? null,
|
||||||
url: this.url,
|
url: this.url,
|
||||||
libraryItemId: this.libraryItem?.id || null,
|
libraryItemId: this.libraryItemId,
|
||||||
libraryId: this.libraryId || null,
|
libraryId: this.libraryId || null,
|
||||||
isFinished: this.isFinished,
|
isFinished: this.isFinished,
|
||||||
failed: this.failed,
|
failed: this.failed,
|
||||||
appendEpisodeId: this.appendEpisodeId,
|
appendRandomId: this.appendRandomId,
|
||||||
startedAt: this.startedAt,
|
startedAt: this.startedAt,
|
||||||
createdAt: this.createdAt,
|
createdAt: this.createdAt,
|
||||||
finishedAt: this.finishedAt,
|
finishedAt: this.finishedAt,
|
||||||
podcastTitle: this.libraryItem?.media.metadata.title ?? null,
|
podcastTitle: this.libraryItem?.media.title ?? null,
|
||||||
podcastExplicit: !!this.libraryItem?.media.metadata.explicit,
|
podcastExplicit: !!this.libraryItem?.media.explicit,
|
||||||
season: this.podcastEpisode?.season ?? null,
|
season: this.rssPodcastEpisode?.season ?? null,
|
||||||
episode: this.podcastEpisode?.episode ?? null,
|
episode: this.rssPodcastEpisode?.episode ?? null,
|
||||||
episodeType: this.podcastEpisode?.episodeType ?? 'full',
|
episodeType: this.rssPodcastEpisode?.episodeType ?? 'full',
|
||||||
publishedAt: this.podcastEpisode?.publishedAt ?? null
|
publishedAt: this.rssPodcastEpisode?.publishedAt ?? null
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -54,7 +57,7 @@ class PodcastEpisodeDownload {
|
|||||||
return 'mp3'
|
return 'mp3'
|
||||||
}
|
}
|
||||||
get enclosureType() {
|
get enclosureType() {
|
||||||
const enclosureType = this.podcastEpisode?.enclosure?.type
|
const enclosureType = this.rssPodcastEpisode.enclosure.type
|
||||||
return typeof enclosureType === 'string' ? enclosureType : null
|
return typeof enclosureType === 'string' ? enclosureType : null
|
||||||
}
|
}
|
||||||
/**
|
/**
|
||||||
@ -67,10 +70,12 @@ class PodcastEpisodeDownload {
|
|||||||
if (this.enclosureType && !this.enclosureType.includes('mpeg')) return false
|
if (this.enclosureType && !this.enclosureType.includes('mpeg')) return false
|
||||||
return this.fileExtension === 'mp3'
|
return this.fileExtension === 'mp3'
|
||||||
}
|
}
|
||||||
|
get episodeTitle() {
|
||||||
|
return this.rssPodcastEpisode.title
|
||||||
|
}
|
||||||
get targetFilename() {
|
get targetFilename() {
|
||||||
const appendage = this.appendEpisodeId ? ` (${this.podcastEpisode.id})` : ''
|
const appendage = this.appendRandomId ? ` (${uuidv4()})` : ''
|
||||||
const filename = `${this.podcastEpisode.title}${appendage}.${this.fileExtension}`
|
const filename = `${this.rssPodcastEpisode.title}${appendage}.${this.fileExtension}`
|
||||||
return sanitizeFilename(filename)
|
return sanitizeFilename(filename)
|
||||||
}
|
}
|
||||||
get targetPath() {
|
get targetPath() {
|
||||||
@ -80,14 +85,25 @@ class PodcastEpisodeDownload {
|
|||||||
return this.targetFilename
|
return this.targetFilename
|
||||||
}
|
}
|
||||||
get libraryItemId() {
|
get libraryItemId() {
|
||||||
return this.libraryItem ? this.libraryItem.id : null
|
return this.libraryItem?.id || null
|
||||||
|
}
|
||||||
|
get pubYear() {
|
||||||
|
if (!this.rssPodcastEpisode.publishedAt) return null
|
||||||
|
return new Date(this.rssPodcastEpisode.publishedAt).getFullYear()
|
||||||
}
|
}
|
||||||
|
|
||||||
setData(podcastEpisode, libraryItem, isAutoDownload, libraryId) {
|
/**
|
||||||
|
*
|
||||||
|
* @param {import('../utils/podcastUtils').RssPodcastEpisode} rssPodcastEpisode - from rss feed
|
||||||
|
* @param {import('../models/LibraryItem')} libraryItem
|
||||||
|
* @param {*} isAutoDownload
|
||||||
|
* @param {*} libraryId
|
||||||
|
*/
|
||||||
|
setData(rssPodcastEpisode, libraryItem, isAutoDownload, libraryId) {
|
||||||
this.id = uuidv4()
|
this.id = uuidv4()
|
||||||
this.podcastEpisode = podcastEpisode
|
this.rssPodcastEpisode = rssPodcastEpisode
|
||||||
|
|
||||||
const url = podcastEpisode.enclosure.url
|
const url = rssPodcastEpisode.enclosure.url
|
||||||
if (decodeURIComponent(url) !== url) {
|
if (decodeURIComponent(url) !== url) {
|
||||||
// Already encoded
|
// Already encoded
|
||||||
this.url = url
|
this.url = url
|
||||||
|
@ -18,6 +18,7 @@ class Stream extends EventEmitter {
|
|||||||
|
|
||||||
this.id = sessionId
|
this.id = sessionId
|
||||||
this.user = user
|
this.user = user
|
||||||
|
/** @type {import('../models/LibraryItem')} */
|
||||||
this.libraryItem = libraryItem
|
this.libraryItem = libraryItem
|
||||||
this.episodeId = episodeId
|
this.episodeId = episodeId
|
||||||
|
|
||||||
@ -40,31 +41,25 @@ class Stream extends EventEmitter {
|
|||||||
this.furthestSegmentCreated = 0
|
this.furthestSegmentCreated = 0
|
||||||
}
|
}
|
||||||
|
|
||||||
get isPodcast() {
|
/**
|
||||||
return this.libraryItem.mediaType === 'podcast'
|
* @returns {import('../models/PodcastEpisode') | null}
|
||||||
}
|
*/
|
||||||
get episode() {
|
get episode() {
|
||||||
if (!this.isPodcast) return null
|
if (!this.libraryItem.isPodcast) return null
|
||||||
return this.libraryItem.media.episodes.find((ep) => ep.id === this.episodeId)
|
return this.libraryItem.media.podcastEpisodes.find((ep) => ep.id === this.episodeId)
|
||||||
}
|
|
||||||
get libraryItemId() {
|
|
||||||
return this.libraryItem.id
|
|
||||||
}
|
}
|
||||||
get mediaTitle() {
|
get mediaTitle() {
|
||||||
if (this.episode) return this.episode.title || ''
|
return this.libraryItem.media.getPlaybackTitle(this.episodeId)
|
||||||
return this.libraryItem.media.metadata.title || ''
|
|
||||||
}
|
}
|
||||||
get totalDuration() {
|
get totalDuration() {
|
||||||
if (this.episode) return this.episode.duration
|
return this.libraryItem.media.getPlaybackDuration(this.episodeId)
|
||||||
return this.libraryItem.media.duration
|
|
||||||
}
|
}
|
||||||
get tracks() {
|
get tracks() {
|
||||||
if (this.episode) return this.episode.tracks
|
return this.libraryItem.getTrackList(this.episodeId)
|
||||||
return this.libraryItem.media.tracks
|
|
||||||
}
|
}
|
||||||
get tracksAudioFileType() {
|
get tracksAudioFileType() {
|
||||||
if (!this.tracks.length) return null
|
if (!this.tracks.length) return null
|
||||||
return this.tracks[0].metadata.format
|
return this.tracks[0].metadata.ext.slice(1)
|
||||||
}
|
}
|
||||||
get tracksMimeType() {
|
get tracksMimeType() {
|
||||||
if (!this.tracks.length) return null
|
if (!this.tracks.length) return null
|
||||||
@ -116,8 +111,8 @@ class Stream extends EventEmitter {
|
|||||||
return {
|
return {
|
||||||
id: this.id,
|
id: this.id,
|
||||||
userId: this.user.id,
|
userId: this.user.id,
|
||||||
libraryItem: this.libraryItem.toJSONExpanded(),
|
libraryItem: this.libraryItem.toOldJSONExpanded(),
|
||||||
episode: this.episode ? this.episode.toJSONExpanded() : null,
|
episode: this.episode ? this.episode.toOldJSONExpanded(this.libraryItem.id) : null,
|
||||||
segmentLength: this.segmentLength,
|
segmentLength: this.segmentLength,
|
||||||
playlistPath: this.playlistPath,
|
playlistPath: this.playlistPath,
|
||||||
clientPlaylistUri: this.clientPlaylistUri,
|
clientPlaylistUri: this.clientPlaylistUri,
|
||||||
@ -280,15 +275,15 @@ class Stream extends EventEmitter {
|
|||||||
|
|
||||||
this.ffmpeg.addOption([`-loglevel ${logLevel}`, '-map 0:a', `-c:a ${audioCodec}`])
|
this.ffmpeg.addOption([`-loglevel ${logLevel}`, '-map 0:a', `-c:a ${audioCodec}`])
|
||||||
const hlsOptions = ['-f hls', '-copyts', '-avoid_negative_ts make_non_negative', '-max_delay 5000000', '-max_muxing_queue_size 2048', `-hls_time 6`, `-hls_segment_type ${this.hlsSegmentType}`, `-start_number ${this.segmentStartNumber}`, '-hls_playlist_type vod', '-hls_list_size 0', '-hls_allow_cache 0']
|
const hlsOptions = ['-f hls', '-copyts', '-avoid_negative_ts make_non_negative', '-max_delay 5000000', '-max_muxing_queue_size 2048', `-hls_time 6`, `-hls_segment_type ${this.hlsSegmentType}`, `-start_number ${this.segmentStartNumber}`, '-hls_playlist_type vod', '-hls_list_size 0', '-hls_allow_cache 0']
|
||||||
|
this.ffmpeg.addOption(hlsOptions)
|
||||||
if (this.hlsSegmentType === 'fmp4') {
|
if (this.hlsSegmentType === 'fmp4') {
|
||||||
hlsOptions.push('-strict -2')
|
this.ffmpeg.addOption('-strict -2')
|
||||||
var fmp4InitFilename = Path.join(this.streamPath, 'init.mp4')
|
var fmp4InitFilename = Path.join(this.streamPath, 'init.mp4')
|
||||||
// var fmp4InitFilename = 'init.mp4'
|
// var fmp4InitFilename = 'init.mp4'
|
||||||
hlsOptions.push(`-hls_fmp4_init_filename ${fmp4InitFilename}`)
|
this.ffmpeg.addOption('-hls_fmp4_init_filename', fmp4InitFilename)
|
||||||
}
|
}
|
||||||
this.ffmpeg.addOption(hlsOptions)
|
|
||||||
var segmentFilename = Path.join(this.streamPath, this.segmentBasename)
|
var segmentFilename = Path.join(this.streamPath, this.segmentBasename)
|
||||||
this.ffmpeg.addOption(`-hls_segment_filename ${segmentFilename}`)
|
this.ffmpeg.addOption('-hls_segment_filename', segmentFilename)
|
||||||
this.ffmpeg.output(this.finalPlaylistPath)
|
this.ffmpeg.output(this.finalPlaylistPath)
|
||||||
|
|
||||||
this.ffmpeg.on('start', (command) => {
|
this.ffmpeg.on('start', (command) => {
|
||||||
|
@ -1,186 +0,0 @@
|
|||||||
const uuidv4 = require('uuid').v4
|
|
||||||
const { areEquivalent, copyValue } = require('../../utils/index')
|
|
||||||
const AudioFile = require('../files/AudioFile')
|
|
||||||
const AudioTrack = require('../files/AudioTrack')
|
|
||||||
|
|
||||||
class PodcastEpisode {
|
|
||||||
constructor(episode) {
|
|
||||||
this.libraryItemId = null
|
|
||||||
this.podcastId = null
|
|
||||||
this.id = null
|
|
||||||
this.oldEpisodeId = null
|
|
||||||
this.index = null
|
|
||||||
|
|
||||||
this.season = null
|
|
||||||
this.episode = null
|
|
||||||
this.episodeType = null
|
|
||||||
this.title = null
|
|
||||||
this.subtitle = null
|
|
||||||
this.description = null
|
|
||||||
this.enclosure = null
|
|
||||||
this.guid = null
|
|
||||||
this.pubDate = null
|
|
||||||
this.chapters = []
|
|
||||||
|
|
||||||
this.audioFile = null
|
|
||||||
this.publishedAt = null
|
|
||||||
this.addedAt = null
|
|
||||||
this.updatedAt = null
|
|
||||||
|
|
||||||
if (episode) {
|
|
||||||
this.construct(episode)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
construct(episode) {
|
|
||||||
this.libraryItemId = episode.libraryItemId
|
|
||||||
this.podcastId = episode.podcastId
|
|
||||||
this.id = episode.id
|
|
||||||
this.oldEpisodeId = episode.oldEpisodeId
|
|
||||||
this.index = episode.index
|
|
||||||
this.season = episode.season
|
|
||||||
this.episode = episode.episode
|
|
||||||
this.episodeType = episode.episodeType
|
|
||||||
this.title = episode.title
|
|
||||||
this.subtitle = episode.subtitle
|
|
||||||
this.description = episode.description
|
|
||||||
this.enclosure = episode.enclosure ? { ...episode.enclosure } : null
|
|
||||||
this.guid = episode.guid || null
|
|
||||||
this.pubDate = episode.pubDate
|
|
||||||
this.chapters = episode.chapters?.map((ch) => ({ ...ch })) || []
|
|
||||||
this.audioFile = episode.audioFile ? new AudioFile(episode.audioFile) : null
|
|
||||||
this.publishedAt = episode.publishedAt
|
|
||||||
this.addedAt = episode.addedAt
|
|
||||||
this.updatedAt = episode.updatedAt
|
|
||||||
|
|
||||||
if (this.audioFile) {
|
|
||||||
this.audioFile.index = 1 // Only 1 audio file per episode
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSON() {
|
|
||||||
return {
|
|
||||||
libraryItemId: this.libraryItemId,
|
|
||||||
podcastId: this.podcastId,
|
|
||||||
id: this.id,
|
|
||||||
oldEpisodeId: this.oldEpisodeId,
|
|
||||||
index: this.index,
|
|
||||||
season: this.season,
|
|
||||||
episode: this.episode,
|
|
||||||
episodeType: this.episodeType,
|
|
||||||
title: this.title,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
description: this.description,
|
|
||||||
enclosure: this.enclosure ? { ...this.enclosure } : null,
|
|
||||||
guid: this.guid,
|
|
||||||
pubDate: this.pubDate,
|
|
||||||
chapters: this.chapters.map((ch) => ({ ...ch })),
|
|
||||||
audioFile: this.audioFile?.toJSON() || null,
|
|
||||||
publishedAt: this.publishedAt,
|
|
||||||
addedAt: this.addedAt,
|
|
||||||
updatedAt: this.updatedAt
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONExpanded() {
|
|
||||||
return {
|
|
||||||
libraryItemId: this.libraryItemId,
|
|
||||||
podcastId: this.podcastId,
|
|
||||||
id: this.id,
|
|
||||||
oldEpisodeId: this.oldEpisodeId,
|
|
||||||
index: this.index,
|
|
||||||
season: this.season,
|
|
||||||
episode: this.episode,
|
|
||||||
episodeType: this.episodeType,
|
|
||||||
title: this.title,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
description: this.description,
|
|
||||||
enclosure: this.enclosure ? { ...this.enclosure } : null,
|
|
||||||
guid: this.guid,
|
|
||||||
pubDate: this.pubDate,
|
|
||||||
chapters: this.chapters.map((ch) => ({ ...ch })),
|
|
||||||
audioFile: this.audioFile?.toJSON() || null,
|
|
||||||
audioTrack: this.audioTrack?.toJSON() || null,
|
|
||||||
publishedAt: this.publishedAt,
|
|
||||||
addedAt: this.addedAt,
|
|
||||||
updatedAt: this.updatedAt,
|
|
||||||
duration: this.duration,
|
|
||||||
size: this.size
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
get audioTrack() {
|
|
||||||
if (!this.audioFile) return null
|
|
||||||
const audioTrack = new AudioTrack()
|
|
||||||
audioTrack.setData(this.libraryItemId, this.audioFile, 0)
|
|
||||||
return audioTrack
|
|
||||||
}
|
|
||||||
get tracks() {
|
|
||||||
return [this.audioTrack]
|
|
||||||
}
|
|
||||||
get duration() {
|
|
||||||
return this.audioFile?.duration || 0
|
|
||||||
}
|
|
||||||
get size() {
|
|
||||||
return this.audioFile?.metadata.size || 0
|
|
||||||
}
|
|
||||||
get enclosureUrl() {
|
|
||||||
return this.enclosure?.url || null
|
|
||||||
}
|
|
||||||
get pubYear() {
|
|
||||||
if (!this.publishedAt) return null
|
|
||||||
return new Date(this.publishedAt).getFullYear()
|
|
||||||
}
|
|
||||||
|
|
||||||
setData(data, index = 1) {
|
|
||||||
this.id = uuidv4()
|
|
||||||
this.index = index
|
|
||||||
this.title = data.title
|
|
||||||
this.subtitle = data.subtitle || ''
|
|
||||||
this.pubDate = data.pubDate || ''
|
|
||||||
this.description = data.description || ''
|
|
||||||
this.enclosure = data.enclosure ? { ...data.enclosure } : null
|
|
||||||
this.guid = data.guid || null
|
|
||||||
this.season = data.season || ''
|
|
||||||
this.episode = data.episode || ''
|
|
||||||
this.episodeType = data.episodeType || 'full'
|
|
||||||
this.publishedAt = data.publishedAt || 0
|
|
||||||
this.addedAt = Date.now()
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
}
|
|
||||||
|
|
||||||
update(payload) {
|
|
||||||
let hasUpdates = false
|
|
||||||
for (const key in this.toJSON()) {
|
|
||||||
let newValue = payload[key]
|
|
||||||
if (newValue === '') newValue = null
|
|
||||||
let existingValue = this[key]
|
|
||||||
if (existingValue === '') existingValue = null
|
|
||||||
|
|
||||||
if (newValue != undefined && !areEquivalent(newValue, existingValue)) {
|
|
||||||
this[key] = copyValue(newValue)
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (hasUpdates) {
|
|
||||||
this.updatedAt = Date.now()
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
// Only checks container format
|
|
||||||
checkCanDirectPlay(payload) {
|
|
||||||
const supportedMimeTypes = payload.supportedMimeTypes || []
|
|
||||||
return supportedMimeTypes.includes(this.audioFile.mimeType)
|
|
||||||
}
|
|
||||||
|
|
||||||
getDirectPlayTracklist() {
|
|
||||||
return this.tracks
|
|
||||||
}
|
|
||||||
|
|
||||||
checkEqualsEnclosureUrl(url) {
|
|
||||||
if (!this.enclosure?.url) return false
|
|
||||||
return this.enclosure.url == url
|
|
||||||
}
|
|
||||||
}
|
|
||||||
module.exports = PodcastEpisode
|
|
@ -1,274 +0,0 @@
|
|||||||
const Logger = require('../../Logger')
|
|
||||||
const BookMetadata = require('../metadata/BookMetadata')
|
|
||||||
const { areEquivalent, copyValue } = require('../../utils/index')
|
|
||||||
const { filePathToPOSIX } = require('../../utils/fileUtils')
|
|
||||||
const AudioFile = require('../files/AudioFile')
|
|
||||||
const AudioTrack = require('../files/AudioTrack')
|
|
||||||
const EBookFile = require('../files/EBookFile')
|
|
||||||
|
|
||||||
class Book {
|
|
||||||
constructor(book) {
|
|
||||||
this.id = null
|
|
||||||
this.libraryItemId = null
|
|
||||||
this.metadata = null
|
|
||||||
|
|
||||||
this.coverPath = null
|
|
||||||
this.tags = []
|
|
||||||
|
|
||||||
this.audioFiles = []
|
|
||||||
this.chapters = []
|
|
||||||
this.ebookFile = null
|
|
||||||
|
|
||||||
this.lastCoverSearch = null
|
|
||||||
this.lastCoverSearchQuery = null
|
|
||||||
|
|
||||||
if (book) {
|
|
||||||
this.construct(book)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
construct(book) {
|
|
||||||
this.id = book.id
|
|
||||||
this.libraryItemId = book.libraryItemId
|
|
||||||
this.metadata = new BookMetadata(book.metadata)
|
|
||||||
this.coverPath = book.coverPath
|
|
||||||
this.tags = [...book.tags]
|
|
||||||
this.audioFiles = book.audioFiles.map(f => new AudioFile(f))
|
|
||||||
this.chapters = book.chapters.map(c => ({ ...c }))
|
|
||||||
this.ebookFile = book.ebookFile ? new EBookFile(book.ebookFile) : null
|
|
||||||
this.lastCoverSearch = book.lastCoverSearch || null
|
|
||||||
this.lastCoverSearchQuery = book.lastCoverSearchQuery || null
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSON() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
libraryItemId: this.libraryItemId,
|
|
||||||
metadata: this.metadata.toJSON(),
|
|
||||||
coverPath: this.coverPath,
|
|
||||||
tags: [...this.tags],
|
|
||||||
audioFiles: this.audioFiles.map(f => f.toJSON()),
|
|
||||||
chapters: this.chapters.map(c => ({ ...c })),
|
|
||||||
ebookFile: this.ebookFile ? this.ebookFile.toJSON() : null
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONMinified() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
metadata: this.metadata.toJSONMinified(),
|
|
||||||
coverPath: this.coverPath,
|
|
||||||
tags: [...this.tags],
|
|
||||||
numTracks: this.tracks.length,
|
|
||||||
numAudioFiles: this.audioFiles.length,
|
|
||||||
numChapters: this.chapters.length,
|
|
||||||
duration: this.duration,
|
|
||||||
size: this.size,
|
|
||||||
ebookFormat: this.ebookFile?.ebookFormat
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONExpanded() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
libraryItemId: this.libraryItemId,
|
|
||||||
metadata: this.metadata.toJSONExpanded(),
|
|
||||||
coverPath: this.coverPath,
|
|
||||||
tags: [...this.tags],
|
|
||||||
audioFiles: this.audioFiles.map(f => f.toJSON()),
|
|
||||||
chapters: this.chapters.map(c => ({ ...c })),
|
|
||||||
duration: this.duration,
|
|
||||||
size: this.size,
|
|
||||||
tracks: this.tracks.map(t => t.toJSON()),
|
|
||||||
ebookFile: this.ebookFile?.toJSON() || null
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONForMetadataFile() {
|
|
||||||
return {
|
|
||||||
tags: [...this.tags],
|
|
||||||
chapters: this.chapters.map(c => ({ ...c })),
|
|
||||||
...this.metadata.toJSONForMetadataFile()
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
get size() {
|
|
||||||
var total = 0
|
|
||||||
this.audioFiles.forEach((af) => total += af.metadata.size)
|
|
||||||
if (this.ebookFile) {
|
|
||||||
total += this.ebookFile.metadata.size
|
|
||||||
}
|
|
||||||
return total
|
|
||||||
}
|
|
||||||
get hasMediaEntities() {
|
|
||||||
return !!this.tracks.length || this.ebookFile
|
|
||||||
}
|
|
||||||
get includedAudioFiles() {
|
|
||||||
return this.audioFiles.filter(af => !af.exclude)
|
|
||||||
}
|
|
||||||
get tracks() {
|
|
||||||
let startOffset = 0
|
|
||||||
return this.includedAudioFiles.map((af) => {
|
|
||||||
const audioTrack = new AudioTrack()
|
|
||||||
audioTrack.setData(this.libraryItemId, af, startOffset)
|
|
||||||
startOffset += audioTrack.duration
|
|
||||||
return audioTrack
|
|
||||||
})
|
|
||||||
}
|
|
||||||
get duration() {
|
|
||||||
let total = 0
|
|
||||||
this.tracks.forEach((track) => total += track.duration)
|
|
||||||
return total
|
|
||||||
}
|
|
||||||
get numTracks() {
|
|
||||||
return this.tracks.length
|
|
||||||
}
|
|
||||||
get isEBookOnly() {
|
|
||||||
return this.ebookFile && !this.numTracks
|
|
||||||
}
|
|
||||||
|
|
||||||
update(payload) {
|
|
||||||
const json = this.toJSON()
|
|
||||||
delete json.audiobooks // do not update media entities here
|
|
||||||
delete json.ebooks
|
|
||||||
|
|
||||||
let hasUpdates = false
|
|
||||||
for (const key in json) {
|
|
||||||
if (payload[key] !== undefined) {
|
|
||||||
if (key === 'metadata') {
|
|
||||||
if (this.metadata.update(payload.metadata)) {
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
} else if (!areEquivalent(payload[key], json[key])) {
|
|
||||||
this[key] = copyValue(payload[key])
|
|
||||||
Logger.debug('[Book] Key updated', key, this[key])
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
updateChapters(chapters) {
|
|
||||||
var hasUpdates = this.chapters.length !== chapters.length
|
|
||||||
if (hasUpdates) {
|
|
||||||
this.chapters = chapters.map(ch => ({
|
|
||||||
id: ch.id,
|
|
||||||
start: ch.start,
|
|
||||||
end: ch.end,
|
|
||||||
title: ch.title
|
|
||||||
}))
|
|
||||||
} else {
|
|
||||||
for (let i = 0; i < this.chapters.length; i++) {
|
|
||||||
const currChapter = this.chapters[i]
|
|
||||||
const newChapter = chapters[i]
|
|
||||||
if (!hasUpdates && (currChapter.title !== newChapter.title || currChapter.start !== newChapter.start || currChapter.end !== newChapter.end)) {
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
this.chapters[i].title = newChapter.title
|
|
||||||
this.chapters[i].start = newChapter.start
|
|
||||||
this.chapters[i].end = newChapter.end
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
updateCover(coverPath) {
|
|
||||||
coverPath = filePathToPOSIX(coverPath)
|
|
||||||
if (this.coverPath === coverPath) return false
|
|
||||||
this.coverPath = coverPath
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
removeFileWithInode(inode) {
|
|
||||||
if (this.audioFiles.some(af => af.ino === inode)) {
|
|
||||||
this.audioFiles = this.audioFiles.filter(af => af.ino !== inode)
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
if (this.ebookFile && this.ebookFile.ino === inode) {
|
|
||||||
this.ebookFile = null
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
return false
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Get audio file or ebook file from inode
|
|
||||||
* @param {string} inode
|
|
||||||
* @returns {(AudioFile|EBookFile|null)}
|
|
||||||
*/
|
|
||||||
findFileWithInode(inode) {
|
|
||||||
const audioFile = this.audioFiles.find(af => af.ino === inode)
|
|
||||||
if (audioFile) return audioFile
|
|
||||||
if (this.ebookFile && this.ebookFile.ino === inode) return this.ebookFile
|
|
||||||
return null
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* Set the EBookFile from a LibraryFile
|
|
||||||
* If null then ebookFile will be removed from the book
|
|
||||||
*
|
|
||||||
* @param {LibraryFile} [libraryFile]
|
|
||||||
*/
|
|
||||||
setEbookFile(libraryFile = null) {
|
|
||||||
if (!libraryFile) {
|
|
||||||
this.ebookFile = null
|
|
||||||
} else {
|
|
||||||
const ebookFile = new EBookFile()
|
|
||||||
ebookFile.setData(libraryFile)
|
|
||||||
this.ebookFile = ebookFile
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
addAudioFile(audioFile) {
|
|
||||||
this.audioFiles.push(audioFile)
|
|
||||||
}
|
|
||||||
|
|
||||||
updateAudioTracks(orderedFileData) {
|
|
||||||
let index = 1
|
|
||||||
this.audioFiles = orderedFileData.map((fileData) => {
|
|
||||||
const audioFile = this.audioFiles.find(af => af.ino === fileData.ino)
|
|
||||||
audioFile.manuallyVerified = true
|
|
||||||
audioFile.error = null
|
|
||||||
if (fileData.exclude !== undefined) {
|
|
||||||
audioFile.exclude = !!fileData.exclude
|
|
||||||
}
|
|
||||||
if (audioFile.exclude) {
|
|
||||||
audioFile.index = -1
|
|
||||||
} else {
|
|
||||||
audioFile.index = index++
|
|
||||||
}
|
|
||||||
return audioFile
|
|
||||||
})
|
|
||||||
|
|
||||||
this.rebuildTracks()
|
|
||||||
}
|
|
||||||
|
|
||||||
rebuildTracks() {
|
|
||||||
Logger.debug(`[Book] Tracks being rebuilt...!`)
|
|
||||||
this.audioFiles.sort((a, b) => a.index - b.index)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Only checks container format
|
|
||||||
checkCanDirectPlay(payload) {
|
|
||||||
var supportedMimeTypes = payload.supportedMimeTypes || []
|
|
||||||
return !this.tracks.some((t) => !supportedMimeTypes.includes(t.mimeType))
|
|
||||||
}
|
|
||||||
|
|
||||||
getDirectPlayTracklist() {
|
|
||||||
return this.tracks
|
|
||||||
}
|
|
||||||
|
|
||||||
getPlaybackTitle() {
|
|
||||||
return this.metadata.title
|
|
||||||
}
|
|
||||||
|
|
||||||
getPlaybackAuthor() {
|
|
||||||
return this.metadata.authorName
|
|
||||||
}
|
|
||||||
|
|
||||||
getChapters() {
|
|
||||||
return this.chapters?.map(ch => ({ ...ch })) || []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
module.exports = Book
|
|
@ -1,273 +0,0 @@
|
|||||||
const Logger = require('../../Logger')
|
|
||||||
const PodcastEpisode = require('../entities/PodcastEpisode')
|
|
||||||
const PodcastMetadata = require('../metadata/PodcastMetadata')
|
|
||||||
const { areEquivalent, copyValue } = require('../../utils/index')
|
|
||||||
const { filePathToPOSIX } = require('../../utils/fileUtils')
|
|
||||||
|
|
||||||
class Podcast {
|
|
||||||
constructor(podcast) {
|
|
||||||
this.id = null
|
|
||||||
this.libraryItemId = null
|
|
||||||
this.metadata = null
|
|
||||||
this.coverPath = null
|
|
||||||
this.tags = []
|
|
||||||
this.episodes = []
|
|
||||||
|
|
||||||
this.autoDownloadEpisodes = false
|
|
||||||
this.autoDownloadSchedule = null
|
|
||||||
this.lastEpisodeCheck = 0
|
|
||||||
this.maxEpisodesToKeep = 0
|
|
||||||
this.maxNewEpisodesToDownload = 3
|
|
||||||
|
|
||||||
this.lastCoverSearch = null
|
|
||||||
this.lastCoverSearchQuery = null
|
|
||||||
|
|
||||||
if (podcast) {
|
|
||||||
this.construct(podcast)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
construct(podcast) {
|
|
||||||
this.id = podcast.id
|
|
||||||
this.libraryItemId = podcast.libraryItemId
|
|
||||||
this.metadata = new PodcastMetadata(podcast.metadata)
|
|
||||||
this.coverPath = podcast.coverPath
|
|
||||||
this.tags = [...podcast.tags]
|
|
||||||
this.episodes = podcast.episodes.map((e) => {
|
|
||||||
var podcastEpisode = new PodcastEpisode(e)
|
|
||||||
podcastEpisode.libraryItemId = this.libraryItemId
|
|
||||||
return podcastEpisode
|
|
||||||
})
|
|
||||||
this.autoDownloadEpisodes = !!podcast.autoDownloadEpisodes
|
|
||||||
this.autoDownloadSchedule = podcast.autoDownloadSchedule || '0 * * * *' // Added in 2.1.3 so default to hourly
|
|
||||||
this.lastEpisodeCheck = podcast.lastEpisodeCheck || 0
|
|
||||||
this.maxEpisodesToKeep = podcast.maxEpisodesToKeep || 0
|
|
||||||
|
|
||||||
// Default is 3 but 0 is allowed
|
|
||||||
if (typeof podcast.maxNewEpisodesToDownload !== 'number') {
|
|
||||||
this.maxNewEpisodesToDownload = 3
|
|
||||||
} else {
|
|
||||||
this.maxNewEpisodesToDownload = podcast.maxNewEpisodesToDownload
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSON() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
libraryItemId: this.libraryItemId,
|
|
||||||
metadata: this.metadata.toJSON(),
|
|
||||||
coverPath: this.coverPath,
|
|
||||||
tags: [...this.tags],
|
|
||||||
episodes: this.episodes.map((e) => e.toJSON()),
|
|
||||||
autoDownloadEpisodes: this.autoDownloadEpisodes,
|
|
||||||
autoDownloadSchedule: this.autoDownloadSchedule,
|
|
||||||
lastEpisodeCheck: this.lastEpisodeCheck,
|
|
||||||
maxEpisodesToKeep: this.maxEpisodesToKeep,
|
|
||||||
maxNewEpisodesToDownload: this.maxNewEpisodesToDownload
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONMinified() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
metadata: this.metadata.toJSONMinified(),
|
|
||||||
coverPath: this.coverPath,
|
|
||||||
tags: [...this.tags],
|
|
||||||
numEpisodes: this.episodes.length,
|
|
||||||
autoDownloadEpisodes: this.autoDownloadEpisodes,
|
|
||||||
autoDownloadSchedule: this.autoDownloadSchedule,
|
|
||||||
lastEpisodeCheck: this.lastEpisodeCheck,
|
|
||||||
maxEpisodesToKeep: this.maxEpisodesToKeep,
|
|
||||||
maxNewEpisodesToDownload: this.maxNewEpisodesToDownload,
|
|
||||||
size: this.size
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONExpanded() {
|
|
||||||
return {
|
|
||||||
id: this.id,
|
|
||||||
libraryItemId: this.libraryItemId,
|
|
||||||
metadata: this.metadata.toJSONExpanded(),
|
|
||||||
coverPath: this.coverPath,
|
|
||||||
tags: [...this.tags],
|
|
||||||
episodes: this.episodes.map((e) => e.toJSONExpanded()),
|
|
||||||
autoDownloadEpisodes: this.autoDownloadEpisodes,
|
|
||||||
autoDownloadSchedule: this.autoDownloadSchedule,
|
|
||||||
lastEpisodeCheck: this.lastEpisodeCheck,
|
|
||||||
maxEpisodesToKeep: this.maxEpisodesToKeep,
|
|
||||||
maxNewEpisodesToDownload: this.maxNewEpisodesToDownload,
|
|
||||||
size: this.size
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONForMetadataFile() {
|
|
||||||
return {
|
|
||||||
tags: [...this.tags],
|
|
||||||
title: this.metadata.title,
|
|
||||||
author: this.metadata.author,
|
|
||||||
description: this.metadata.description,
|
|
||||||
releaseDate: this.metadata.releaseDate,
|
|
||||||
genres: [...this.metadata.genres],
|
|
||||||
feedURL: this.metadata.feedUrl,
|
|
||||||
imageURL: this.metadata.imageUrl,
|
|
||||||
itunesPageURL: this.metadata.itunesPageUrl,
|
|
||||||
itunesId: this.metadata.itunesId,
|
|
||||||
itunesArtistId: this.metadata.itunesArtistId,
|
|
||||||
explicit: this.metadata.explicit,
|
|
||||||
language: this.metadata.language,
|
|
||||||
podcastType: this.metadata.type
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
get size() {
|
|
||||||
var total = 0
|
|
||||||
this.episodes.forEach((ep) => (total += ep.size))
|
|
||||||
return total
|
|
||||||
}
|
|
||||||
get hasMediaEntities() {
|
|
||||||
return !!this.episodes.length
|
|
||||||
}
|
|
||||||
get duration() {
|
|
||||||
let total = 0
|
|
||||||
this.episodes.forEach((ep) => (total += ep.duration))
|
|
||||||
return total
|
|
||||||
}
|
|
||||||
get numTracks() {
|
|
||||||
return this.episodes.length
|
|
||||||
}
|
|
||||||
get latestEpisodePublished() {
|
|
||||||
var largestPublishedAt = 0
|
|
||||||
this.episodes.forEach((ep) => {
|
|
||||||
if (ep.publishedAt && ep.publishedAt > largestPublishedAt) {
|
|
||||||
largestPublishedAt = ep.publishedAt
|
|
||||||
}
|
|
||||||
})
|
|
||||||
return largestPublishedAt
|
|
||||||
}
|
|
||||||
get episodesWithPubDate() {
|
|
||||||
return this.episodes.filter((ep) => !!ep.publishedAt)
|
|
||||||
}
|
|
||||||
|
|
||||||
update(payload) {
|
|
||||||
var json = this.toJSON()
|
|
||||||
delete json.episodes // do not update media entities here
|
|
||||||
var hasUpdates = false
|
|
||||||
for (const key in json) {
|
|
||||||
if (payload[key] !== undefined) {
|
|
||||||
if (key === 'metadata') {
|
|
||||||
if (this.metadata.update(payload.metadata)) {
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
} else if (!areEquivalent(payload[key], json[key])) {
|
|
||||||
this[key] = copyValue(payload[key])
|
|
||||||
Logger.debug('[Podcast] Key updated', key, this[key])
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
|
|
||||||
updateEpisode(id, payload) {
|
|
||||||
var episode = this.episodes.find((ep) => ep.id == id)
|
|
||||||
if (!episode) return false
|
|
||||||
return episode.update(payload)
|
|
||||||
}
|
|
||||||
|
|
||||||
updateCover(coverPath) {
|
|
||||||
coverPath = filePathToPOSIX(coverPath)
|
|
||||||
if (this.coverPath === coverPath) return false
|
|
||||||
this.coverPath = coverPath
|
|
||||||
return true
|
|
||||||
}
|
|
||||||
|
|
||||||
removeFileWithInode(inode) {
|
|
||||||
const hasEpisode = this.episodes.some((ep) => ep.audioFile.ino === inode)
|
|
||||||
if (hasEpisode) {
|
|
||||||
this.episodes = this.episodes.filter((ep) => ep.audioFile.ino !== inode)
|
|
||||||
}
|
|
||||||
return hasEpisode
|
|
||||||
}
|
|
||||||
|
|
||||||
findFileWithInode(inode) {
|
|
||||||
var episode = this.episodes.find((ep) => ep.audioFile.ino === inode)
|
|
||||||
if (episode) return episode.audioFile
|
|
||||||
return null
|
|
||||||
}
|
|
||||||
|
|
||||||
setData(mediaData) {
|
|
||||||
this.metadata = new PodcastMetadata()
|
|
||||||
if (mediaData.metadata) {
|
|
||||||
this.metadata.setData(mediaData.metadata)
|
|
||||||
}
|
|
||||||
|
|
||||||
this.coverPath = mediaData.coverPath || null
|
|
||||||
this.autoDownloadEpisodes = !!mediaData.autoDownloadEpisodes
|
|
||||||
this.autoDownloadSchedule = mediaData.autoDownloadSchedule || global.ServerSettings.podcastEpisodeSchedule
|
|
||||||
this.lastEpisodeCheck = Date.now() // Makes sure new episodes are after this
|
|
||||||
}
|
|
||||||
|
|
||||||
checkHasEpisode(episodeId) {
|
|
||||||
return this.episodes.some((ep) => ep.id === episodeId)
|
|
||||||
}
|
|
||||||
checkHasEpisodeByFeedEpisode(feedEpisode) {
|
|
||||||
const guid = feedEpisode.guid
|
|
||||||
const url = feedEpisode.enclosure.url
|
|
||||||
return this.episodes.some((ep) => (ep.guid && ep.guid === guid) || ep.checkEqualsEnclosureUrl(url))
|
|
||||||
}
|
|
||||||
|
|
||||||
// Only checks container format
|
|
||||||
checkCanDirectPlay(payload, episodeId) {
|
|
||||||
var episode = this.episodes.find((ep) => ep.id === episodeId)
|
|
||||||
if (!episode) return false
|
|
||||||
return episode.checkCanDirectPlay(payload)
|
|
||||||
}
|
|
||||||
|
|
||||||
getDirectPlayTracklist(episodeId) {
|
|
||||||
var episode = this.episodes.find((ep) => ep.id === episodeId)
|
|
||||||
if (!episode) return false
|
|
||||||
return episode.getDirectPlayTracklist()
|
|
||||||
}
|
|
||||||
|
|
||||||
addPodcastEpisode(podcastEpisode) {
|
|
||||||
this.episodes.push(podcastEpisode)
|
|
||||||
}
|
|
||||||
|
|
||||||
removeEpisode(episodeId) {
|
|
||||||
const episode = this.episodes.find((ep) => ep.id === episodeId)
|
|
||||||
if (episode) {
|
|
||||||
this.episodes = this.episodes.filter((ep) => ep.id !== episodeId)
|
|
||||||
}
|
|
||||||
return episode
|
|
||||||
}
|
|
||||||
|
|
||||||
getPlaybackTitle(episodeId) {
|
|
||||||
var episode = this.episodes.find((ep) => ep.id == episodeId)
|
|
||||||
if (!episode) return this.metadata.title
|
|
||||||
return episode.title
|
|
||||||
}
|
|
||||||
|
|
||||||
getPlaybackAuthor() {
|
|
||||||
return this.metadata.author
|
|
||||||
}
|
|
||||||
|
|
||||||
getEpisodeDuration(episodeId) {
|
|
||||||
var episode = this.episodes.find((ep) => ep.id == episodeId)
|
|
||||||
if (!episode) return 0
|
|
||||||
return episode.duration
|
|
||||||
}
|
|
||||||
|
|
||||||
getEpisode(episodeId) {
|
|
||||||
if (!episodeId) return null
|
|
||||||
|
|
||||||
// Support old episode ids for mobile downloads
|
|
||||||
if (episodeId.startsWith('ep_')) return this.episodes.find((ep) => ep.oldEpisodeId == episodeId)
|
|
||||||
|
|
||||||
return this.episodes.find((ep) => ep.id == episodeId)
|
|
||||||
}
|
|
||||||
|
|
||||||
getChapters(episodeId) {
|
|
||||||
return this.getEpisode(episodeId)?.chapters?.map((ch) => ({ ...ch })) || []
|
|
||||||
}
|
|
||||||
}
|
|
||||||
module.exports = Podcast
|
|
@ -1,184 +0,0 @@
|
|||||||
const Logger = require('../../Logger')
|
|
||||||
const { areEquivalent, copyValue, getTitleIgnorePrefix, getTitlePrefixAtEnd } = require('../../utils/index')
|
|
||||||
const parseNameString = require('../../utils/parsers/parseNameString')
|
|
||||||
class BookMetadata {
|
|
||||||
constructor(metadata) {
|
|
||||||
this.title = null
|
|
||||||
this.subtitle = null
|
|
||||||
this.authors = []
|
|
||||||
this.narrators = [] // Array of strings
|
|
||||||
this.series = []
|
|
||||||
this.genres = [] // Array of strings
|
|
||||||
this.publishedYear = null
|
|
||||||
this.publishedDate = null
|
|
||||||
this.publisher = null
|
|
||||||
this.description = null
|
|
||||||
this.isbn = null
|
|
||||||
this.asin = null
|
|
||||||
this.language = null
|
|
||||||
this.explicit = false
|
|
||||||
this.abridged = false
|
|
||||||
|
|
||||||
if (metadata) {
|
|
||||||
this.construct(metadata)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
construct(metadata) {
|
|
||||||
this.title = metadata.title
|
|
||||||
this.subtitle = metadata.subtitle
|
|
||||||
this.authors = metadata.authors?.map ? metadata.authors.map((a) => ({ ...a })) : []
|
|
||||||
this.narrators = metadata.narrators ? [...metadata.narrators].filter((n) => n) : []
|
|
||||||
this.series = metadata.series?.map
|
|
||||||
? metadata.series.map((s) => ({
|
|
||||||
...s,
|
|
||||||
name: s.name || 'No Title'
|
|
||||||
}))
|
|
||||||
: []
|
|
||||||
this.genres = metadata.genres ? [...metadata.genres] : []
|
|
||||||
this.publishedYear = metadata.publishedYear || null
|
|
||||||
this.publishedDate = metadata.publishedDate || null
|
|
||||||
this.publisher = metadata.publisher
|
|
||||||
this.description = metadata.description
|
|
||||||
this.isbn = metadata.isbn
|
|
||||||
this.asin = metadata.asin
|
|
||||||
this.language = metadata.language
|
|
||||||
this.explicit = !!metadata.explicit
|
|
||||||
this.abridged = !!metadata.abridged
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSON() {
|
|
||||||
return {
|
|
||||||
title: this.title,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
authors: this.authors.map((a) => ({ ...a })), // Author JSONMinimal with name and id
|
|
||||||
narrators: [...this.narrators],
|
|
||||||
series: this.series.map((s) => ({ ...s })), // Series JSONMinimal with name, id and sequence
|
|
||||||
genres: [...this.genres],
|
|
||||||
publishedYear: this.publishedYear,
|
|
||||||
publishedDate: this.publishedDate,
|
|
||||||
publisher: this.publisher,
|
|
||||||
description: this.description,
|
|
||||||
isbn: this.isbn,
|
|
||||||
asin: this.asin,
|
|
||||||
language: this.language,
|
|
||||||
explicit: this.explicit,
|
|
||||||
abridged: this.abridged
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONMinified() {
|
|
||||||
return {
|
|
||||||
title: this.title,
|
|
||||||
titleIgnorePrefix: this.titlePrefixAtEnd,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
authorName: this.authorName,
|
|
||||||
authorNameLF: this.authorNameLF,
|
|
||||||
narratorName: this.narratorName,
|
|
||||||
seriesName: this.seriesName,
|
|
||||||
genres: [...this.genres],
|
|
||||||
publishedYear: this.publishedYear,
|
|
||||||
publishedDate: this.publishedDate,
|
|
||||||
publisher: this.publisher,
|
|
||||||
description: this.description,
|
|
||||||
isbn: this.isbn,
|
|
||||||
asin: this.asin,
|
|
||||||
language: this.language,
|
|
||||||
explicit: this.explicit,
|
|
||||||
abridged: this.abridged
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONExpanded() {
|
|
||||||
return {
|
|
||||||
title: this.title,
|
|
||||||
titleIgnorePrefix: this.titlePrefixAtEnd,
|
|
||||||
subtitle: this.subtitle,
|
|
||||||
authors: this.authors.map((a) => ({ ...a })), // Author JSONMinimal with name and id
|
|
||||||
narrators: [...this.narrators],
|
|
||||||
series: this.series.map((s) => ({ ...s })),
|
|
||||||
genres: [...this.genres],
|
|
||||||
publishedYear: this.publishedYear,
|
|
||||||
publishedDate: this.publishedDate,
|
|
||||||
publisher: this.publisher,
|
|
||||||
description: this.description,
|
|
||||||
isbn: this.isbn,
|
|
||||||
asin: this.asin,
|
|
||||||
language: this.language,
|
|
||||||
explicit: this.explicit,
|
|
||||||
authorName: this.authorName,
|
|
||||||
authorNameLF: this.authorNameLF,
|
|
||||||
narratorName: this.narratorName,
|
|
||||||
seriesName: this.seriesName,
|
|
||||||
abridged: this.abridged
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONForMetadataFile() {
|
|
||||||
const json = this.toJSON()
|
|
||||||
json.authors = json.authors.map((au) => au.name)
|
|
||||||
json.series = json.series.map((se) => {
|
|
||||||
if (!se.sequence) return se.name
|
|
||||||
return `${se.name} #${se.sequence}`
|
|
||||||
})
|
|
||||||
return json
|
|
||||||
}
|
|
||||||
|
|
||||||
clone() {
|
|
||||||
return new BookMetadata(this.toJSON())
|
|
||||||
}
|
|
||||||
|
|
||||||
get titleIgnorePrefix() {
|
|
||||||
return getTitleIgnorePrefix(this.title)
|
|
||||||
}
|
|
||||||
get titlePrefixAtEnd() {
|
|
||||||
return getTitlePrefixAtEnd(this.title)
|
|
||||||
}
|
|
||||||
get authorName() {
|
|
||||||
if (!this.authors.length) return ''
|
|
||||||
return this.authors.map((au) => au.name).join(', ')
|
|
||||||
}
|
|
||||||
get authorNameLF() {
|
|
||||||
// Last, First
|
|
||||||
if (!this.authors.length) return ''
|
|
||||||
return this.authors.map((au) => parseNameString.nameToLastFirst(au.name)).join(', ')
|
|
||||||
}
|
|
||||||
get seriesName() {
|
|
||||||
if (!this.series.length) return ''
|
|
||||||
return this.series
|
|
||||||
.map((se) => {
|
|
||||||
if (!se.sequence) return se.name
|
|
||||||
return `${se.name} #${se.sequence}`
|
|
||||||
})
|
|
||||||
.join(', ')
|
|
||||||
}
|
|
||||||
get narratorName() {
|
|
||||||
return this.narrators.join(', ')
|
|
||||||
}
|
|
||||||
|
|
||||||
getSeries(seriesId) {
|
|
||||||
return this.series.find((se) => se.id == seriesId)
|
|
||||||
}
|
|
||||||
getSeriesSequence(seriesId) {
|
|
||||||
const series = this.series.find((se) => se.id == seriesId)
|
|
||||||
if (!series) return null
|
|
||||||
return series.sequence || ''
|
|
||||||
}
|
|
||||||
|
|
||||||
update(payload) {
|
|
||||||
const json = this.toJSON()
|
|
||||||
let hasUpdates = false
|
|
||||||
|
|
||||||
for (const key in json) {
|
|
||||||
if (payload[key] !== undefined) {
|
|
||||||
if (!areEquivalent(payload[key], json[key])) {
|
|
||||||
this[key] = copyValue(payload[key])
|
|
||||||
Logger.debug('[BookMetadata] Key updated', key, this[key])
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
}
|
|
||||||
module.exports = BookMetadata
|
|
@ -1,127 +0,0 @@
|
|||||||
const Logger = require('../../Logger')
|
|
||||||
const { areEquivalent, copyValue, getTitleIgnorePrefix, getTitlePrefixAtEnd } = require('../../utils/index')
|
|
||||||
|
|
||||||
class PodcastMetadata {
|
|
||||||
constructor(metadata) {
|
|
||||||
this.title = null
|
|
||||||
this.author = null
|
|
||||||
this.description = null
|
|
||||||
this.releaseDate = null
|
|
||||||
this.genres = []
|
|
||||||
this.feedUrl = null
|
|
||||||
this.imageUrl = null
|
|
||||||
this.itunesPageUrl = null
|
|
||||||
this.itunesId = null
|
|
||||||
this.itunesArtistId = null
|
|
||||||
this.explicit = false
|
|
||||||
this.language = null
|
|
||||||
this.type = null
|
|
||||||
|
|
||||||
if (metadata) {
|
|
||||||
this.construct(metadata)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
construct(metadata) {
|
|
||||||
this.title = metadata.title
|
|
||||||
this.author = metadata.author
|
|
||||||
this.description = metadata.description
|
|
||||||
this.releaseDate = metadata.releaseDate
|
|
||||||
this.genres = [...metadata.genres]
|
|
||||||
this.feedUrl = metadata.feedUrl
|
|
||||||
this.imageUrl = metadata.imageUrl
|
|
||||||
this.itunesPageUrl = metadata.itunesPageUrl
|
|
||||||
this.itunesId = metadata.itunesId
|
|
||||||
this.itunesArtistId = metadata.itunesArtistId
|
|
||||||
this.explicit = metadata.explicit
|
|
||||||
this.language = metadata.language || null
|
|
||||||
this.type = metadata.type || 'episodic'
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSON() {
|
|
||||||
return {
|
|
||||||
title: this.title,
|
|
||||||
author: this.author,
|
|
||||||
description: this.description,
|
|
||||||
releaseDate: this.releaseDate,
|
|
||||||
genres: [...this.genres],
|
|
||||||
feedUrl: this.feedUrl,
|
|
||||||
imageUrl: this.imageUrl,
|
|
||||||
itunesPageUrl: this.itunesPageUrl,
|
|
||||||
itunesId: this.itunesId,
|
|
||||||
itunesArtistId: this.itunesArtistId,
|
|
||||||
explicit: this.explicit,
|
|
||||||
language: this.language,
|
|
||||||
type: this.type
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONMinified() {
|
|
||||||
return {
|
|
||||||
title: this.title,
|
|
||||||
titleIgnorePrefix: this.titlePrefixAtEnd,
|
|
||||||
author: this.author,
|
|
||||||
description: this.description,
|
|
||||||
releaseDate: this.releaseDate,
|
|
||||||
genres: [...this.genres],
|
|
||||||
feedUrl: this.feedUrl,
|
|
||||||
imageUrl: this.imageUrl,
|
|
||||||
itunesPageUrl: this.itunesPageUrl,
|
|
||||||
itunesId: this.itunesId,
|
|
||||||
itunesArtistId: this.itunesArtistId,
|
|
||||||
explicit: this.explicit,
|
|
||||||
language: this.language,
|
|
||||||
type: this.type
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
toJSONExpanded() {
|
|
||||||
return this.toJSONMinified()
|
|
||||||
}
|
|
||||||
|
|
||||||
clone() {
|
|
||||||
return new PodcastMetadata(this.toJSON())
|
|
||||||
}
|
|
||||||
|
|
||||||
get titleIgnorePrefix() {
|
|
||||||
return getTitleIgnorePrefix(this.title)
|
|
||||||
}
|
|
||||||
|
|
||||||
get titlePrefixAtEnd() {
|
|
||||||
return getTitlePrefixAtEnd(this.title)
|
|
||||||
}
|
|
||||||
|
|
||||||
setData(mediaMetadata = {}) {
|
|
||||||
this.title = mediaMetadata.title || null
|
|
||||||
this.author = mediaMetadata.author || null
|
|
||||||
this.description = mediaMetadata.description || null
|
|
||||||
this.releaseDate = mediaMetadata.releaseDate || null
|
|
||||||
this.feedUrl = mediaMetadata.feedUrl || null
|
|
||||||
this.imageUrl = mediaMetadata.imageUrl || null
|
|
||||||
this.itunesPageUrl = mediaMetadata.itunesPageUrl || null
|
|
||||||
this.itunesId = mediaMetadata.itunesId || null
|
|
||||||
this.itunesArtistId = mediaMetadata.itunesArtistId || null
|
|
||||||
this.explicit = !!mediaMetadata.explicit
|
|
||||||
this.language = mediaMetadata.language || null
|
|
||||||
this.type = mediaMetadata.type || null
|
|
||||||
if (mediaMetadata.genres && mediaMetadata.genres.length) {
|
|
||||||
this.genres = [...mediaMetadata.genres]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
update(payload) {
|
|
||||||
const json = this.toJSON()
|
|
||||||
let hasUpdates = false
|
|
||||||
for (const key in json) {
|
|
||||||
if (payload[key] !== undefined) {
|
|
||||||
if (!areEquivalent(payload[key], json[key])) {
|
|
||||||
this[key] = copyValue(payload[key])
|
|
||||||
Logger.debug('[PodcastMetadata] Key updated', key, this[key])
|
|
||||||
hasUpdates = true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return hasUpdates
|
|
||||||
}
|
|
||||||
}
|
|
||||||
module.exports = PodcastMetadata
|
|
@ -65,7 +65,7 @@ class ApiRouter {
|
|||||||
//
|
//
|
||||||
// Library Routes
|
// Library Routes
|
||||||
//
|
//
|
||||||
this.router.get(/^\/libraries/, this.apiCacheManager.middleware)
|
this.router.get(/^\/libraries/i, this.apiCacheManager.middleware)
|
||||||
this.router.post('/libraries', LibraryController.create.bind(this))
|
this.router.post('/libraries', LibraryController.create.bind(this))
|
||||||
this.router.get('/libraries', LibraryController.findAll.bind(this))
|
this.router.get('/libraries', LibraryController.findAll.bind(this))
|
||||||
this.router.get('/libraries/:id', LibraryController.middleware.bind(this), LibraryController.findOne.bind(this))
|
this.router.get('/libraries/:id', LibraryController.middleware.bind(this), LibraryController.findOne.bind(this))
|
||||||
@ -105,7 +105,6 @@ class ApiRouter {
|
|||||||
this.router.post('/items/batch/scan', LibraryItemController.batchScan.bind(this))
|
this.router.post('/items/batch/scan', LibraryItemController.batchScan.bind(this))
|
||||||
|
|
||||||
this.router.get('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.findOne.bind(this))
|
this.router.get('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.findOne.bind(this))
|
||||||
this.router.patch('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.update.bind(this))
|
|
||||||
this.router.delete('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.delete.bind(this))
|
this.router.delete('/items/:id', LibraryItemController.middleware.bind(this), LibraryItemController.delete.bind(this))
|
||||||
this.router.get('/items/:id/download', LibraryItemController.middleware.bind(this), LibraryItemController.download.bind(this))
|
this.router.get('/items/:id/download', LibraryItemController.middleware.bind(this), LibraryItemController.download.bind(this))
|
||||||
this.router.patch('/items/:id/media', LibraryItemController.middleware.bind(this), LibraryItemController.updateMedia.bind(this))
|
this.router.patch('/items/:id/media', LibraryItemController.middleware.bind(this), LibraryItemController.updateMedia.bind(this))
|
||||||
@ -361,36 +360,7 @@ class ApiRouter {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// remove item from playlists
|
// remove item from playlists
|
||||||
const playlistsWithItem = await Database.playlistModel.getPlaylistsForMediaItemIds(mediaItemIds)
|
await Database.playlistModel.removeMediaItemsFromPlaylists(mediaItemIds)
|
||||||
for (const playlist of playlistsWithItem) {
|
|
||||||
let numMediaItems = playlist.playlistMediaItems.length
|
|
||||||
|
|
||||||
let order = 1
|
|
||||||
// Remove items in playlist and re-order
|
|
||||||
for (const playlistMediaItem of playlist.playlistMediaItems) {
|
|
||||||
if (mediaItemIds.includes(playlistMediaItem.mediaItemId)) {
|
|
||||||
await playlistMediaItem.destroy()
|
|
||||||
numMediaItems--
|
|
||||||
} else {
|
|
||||||
if (playlistMediaItem.order !== order) {
|
|
||||||
playlistMediaItem.update({
|
|
||||||
order
|
|
||||||
})
|
|
||||||
}
|
|
||||||
order++
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// If playlist is now empty then remove it
|
|
||||||
const jsonExpanded = await playlist.getOldJsonExpanded()
|
|
||||||
if (!numMediaItems) {
|
|
||||||
Logger.info(`[ApiRouter] Playlist "${playlist.name}" has no more items - removing it`)
|
|
||||||
await playlist.destroy()
|
|
||||||
SocketAuthority.clientEmitter(playlist.userId, 'playlist_removed', jsonExpanded)
|
|
||||||
} else {
|
|
||||||
SocketAuthority.clientEmitter(playlist.userId, 'playlist_updated', jsonExpanded)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Close rss feed - remove from db and emit socket event
|
// Close rss feed - remove from db and emit socket event
|
||||||
await RssFeedManager.closeFeedForEntityId(libraryItemId)
|
await RssFeedManager.closeFeedForEntityId(libraryItemId)
|
||||||
@ -560,109 +530,5 @@ class ApiRouter {
|
|||||||
})
|
})
|
||||||
return listeningStats
|
return listeningStats
|
||||||
}
|
}
|
||||||
|
|
||||||
async createAuthorsAndSeriesForItemUpdate(mediaPayload, libraryId) {
|
|
||||||
if (mediaPayload.metadata) {
|
|
||||||
const mediaMetadata = mediaPayload.metadata
|
|
||||||
|
|
||||||
// Create new authors if in payload
|
|
||||||
if (mediaMetadata.authors?.length) {
|
|
||||||
const newAuthors = []
|
|
||||||
for (let i = 0; i < mediaMetadata.authors.length; i++) {
|
|
||||||
const authorName = (mediaMetadata.authors[i].name || '').trim()
|
|
||||||
if (!authorName) {
|
|
||||||
Logger.error(`[ApiRouter] Invalid author object, no name`, mediaMetadata.authors[i])
|
|
||||||
mediaMetadata.authors[i].id = null
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mediaMetadata.authors[i].id?.startsWith('new')) {
|
|
||||||
mediaMetadata.authors[i].id = null
|
|
||||||
}
|
|
||||||
|
|
||||||
// Ensure the ID for the author exists
|
|
||||||
if (mediaMetadata.authors[i].id && !(await Database.checkAuthorExists(libraryId, mediaMetadata.authors[i].id))) {
|
|
||||||
Logger.warn(`[ApiRouter] Author id "${mediaMetadata.authors[i].id}" does not exist`)
|
|
||||||
mediaMetadata.authors[i].id = null
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!mediaMetadata.authors[i].id) {
|
|
||||||
let author = await Database.authorModel.getByNameAndLibrary(authorName, libraryId)
|
|
||||||
if (!author) {
|
|
||||||
author = await Database.authorModel.create({
|
|
||||||
name: authorName,
|
|
||||||
lastFirst: Database.authorModel.getLastFirst(authorName),
|
|
||||||
libraryId
|
|
||||||
})
|
|
||||||
Logger.debug(`[ApiRouter] Creating new author "${author.name}"`)
|
|
||||||
newAuthors.push(author)
|
|
||||||
// Update filter data
|
|
||||||
Database.addAuthorToFilterData(libraryId, author.name, author.id)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update ID in original payload
|
|
||||||
mediaMetadata.authors[i].id = author.id
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// Remove authors without an id
|
|
||||||
mediaMetadata.authors = mediaMetadata.authors.filter((au) => !!au.id)
|
|
||||||
if (newAuthors.length) {
|
|
||||||
SocketAuthority.emitter(
|
|
||||||
'authors_added',
|
|
||||||
newAuthors.map((au) => au.toOldJSON())
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Create new series if in payload
|
|
||||||
if (mediaMetadata.series && mediaMetadata.series.length) {
|
|
||||||
const newSeries = []
|
|
||||||
for (let i = 0; i < mediaMetadata.series.length; i++) {
|
|
||||||
const seriesName = (mediaMetadata.series[i].name || '').trim()
|
|
||||||
if (!seriesName) {
|
|
||||||
Logger.error(`[ApiRouter] Invalid series object, no name`, mediaMetadata.series[i])
|
|
||||||
mediaMetadata.series[i].id = null
|
|
||||||
continue
|
|
||||||
}
|
|
||||||
|
|
||||||
if (mediaMetadata.series[i].id?.startsWith('new')) {
|
|
||||||
mediaMetadata.series[i].id = null
|
|
||||||
}
|
|
||||||
|
|
||||||
// Ensure the ID for the series exists
|
|
||||||
if (mediaMetadata.series[i].id && !(await Database.checkSeriesExists(libraryId, mediaMetadata.series[i].id))) {
|
|
||||||
Logger.warn(`[ApiRouter] Series id "${mediaMetadata.series[i].id}" does not exist`)
|
|
||||||
mediaMetadata.series[i].id = null
|
|
||||||
}
|
|
||||||
|
|
||||||
if (!mediaMetadata.series[i].id) {
|
|
||||||
let seriesItem = await Database.seriesModel.getByNameAndLibrary(seriesName, libraryId)
|
|
||||||
if (!seriesItem) {
|
|
||||||
seriesItem = await Database.seriesModel.create({
|
|
||||||
name: seriesName,
|
|
||||||
nameIgnorePrefix: getTitleIgnorePrefix(seriesName),
|
|
||||||
libraryId
|
|
||||||
})
|
|
||||||
Logger.debug(`[ApiRouter] Creating new series "${seriesItem.name}"`)
|
|
||||||
newSeries.push(seriesItem)
|
|
||||||
// Update filter data
|
|
||||||
Database.addSeriesToFilterData(libraryId, seriesItem.name, seriesItem.id)
|
|
||||||
}
|
|
||||||
|
|
||||||
// Update ID in original payload
|
|
||||||
mediaMetadata.series[i].id = seriesItem.id
|
|
||||||
}
|
|
||||||
}
|
|
||||||
// Remove series without an id
|
|
||||||
mediaMetadata.series = mediaMetadata.series.filter((se) => se.id)
|
|
||||||
if (newSeries.length) {
|
|
||||||
SocketAuthority.emitter(
|
|
||||||
'multiple_series_added',
|
|
||||||
newSeries.map((se) => se.toOldJSON())
|
|
||||||
)
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
module.exports = ApiRouter
|
module.exports = ApiRouter
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
x
Reference in New Issue
Block a user