mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2024-12-20 19:06:06 +01:00
Fix ebook url, add opus to uploader, set chapters after track updates
This commit is contained in:
parent
1637b6c7f0
commit
a590e795e3
@ -17,6 +17,8 @@
|
||||
<controls-global-search />
|
||||
<div class="flex-grow" />
|
||||
|
||||
<span v-if="showExperimentalFeatures" class="material-icons text-4xl text-warning pr-4">logo_dev</span>
|
||||
|
||||
<nuxt-link v-if="userCanUpload" to="/upload" class="outline-none hover:text-gray-200 cursor-pointer w-8 h-8 flex items-center justify-center">
|
||||
<span class="material-icons">upload</span>
|
||||
</nuxt-link>
|
||||
@ -117,6 +119,9 @@ export default {
|
||||
},
|
||||
processingBatch() {
|
||||
return this.$store.state.processingBatch
|
||||
},
|
||||
showExperimentalFeatures() {
|
||||
return this.$store.state.showExperimentalFeatures
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
@ -70,7 +70,7 @@ export default {
|
||||
}
|
||||
},
|
||||
fullUrl() {
|
||||
var serverUrl = process.env.serverUrl
|
||||
var serverUrl = process.env.serverUrl || '/local'
|
||||
return `${serverUrl}/${this.url}`
|
||||
}
|
||||
},
|
||||
|
@ -120,9 +120,9 @@ export default {
|
||||
title: null,
|
||||
author: null,
|
||||
series: null,
|
||||
acceptedAudioFormats: ['.mp3', '.m4b', '.m4a', '.flac'],
|
||||
acceptedAudioFormats: ['.mp3', '.m4b', '.m4a', '.flac', '.opus'],
|
||||
acceptedImageFormats: ['.png', '.jpg', '.jpeg', '.webp'],
|
||||
inputAccept: '.png, .jpg, .jpeg, .webp, .mp3, .m4b, .m4a, .flac',
|
||||
inputAccept: '.png, .jpg, .jpeg, .webp, .mp3, .m4b, .m4a, .flac, .opus',
|
||||
isDragOver: false,
|
||||
showUploader: true,
|
||||
validAudioFiles: [],
|
||||
|
@ -6,7 +6,8 @@ module.exports = {
|
||||
safelist: [
|
||||
'bg-success',
|
||||
'bg-red-600',
|
||||
'py-1.5'
|
||||
'py-1.5',
|
||||
'bg-info'
|
||||
]
|
||||
}
|
||||
},
|
||||
|
@ -439,18 +439,21 @@ class Server {
|
||||
})
|
||||
}
|
||||
|
||||
testFileSystem(req, res) {
|
||||
async testFileSystem(req, res) {
|
||||
Logger.debug(`[Server] Running fs test`)
|
||||
var paths = fs.readdir(global.appRoot)
|
||||
var paths = await fs.readdir(global.appRoot)
|
||||
Logger.debug(paths)
|
||||
var pathMap = {}
|
||||
if (paths && paths.length) {
|
||||
for (let i = 0; i < paths.length; i++) {
|
||||
var fullPath = Path.join(global.appRoot, paths[i])
|
||||
Logger.debug('Checking path', fullPath)
|
||||
var _paths = fs.readdir(fullPath)
|
||||
Logger.debug(_paths)
|
||||
pathMap[paths[i]] = _paths
|
||||
var isDirectory = fs.lstatSync(fullPath).isDirectory()
|
||||
if (isDirectory) {
|
||||
var _paths = await fs.readdir(fullPath)
|
||||
Logger.debug(_paths)
|
||||
pathMap[paths[i]] = _paths
|
||||
}
|
||||
}
|
||||
}
|
||||
Logger.debug('Finished fs test')
|
||||
|
@ -390,6 +390,7 @@ class Audiobook {
|
||||
this.addTrack(file)
|
||||
}
|
||||
})
|
||||
this.setChapters()
|
||||
this.lastUpdate = Date.now()
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user