mirror of
https://github.com/advplyr/audiobookshelf-app.git
synced 2025-08-03 01:24:37 +02:00
Fix: more sync issues, Add: link audiobooks with folder names in selected download folder
This commit is contained in:
parent
3b6e7e1ce2
commit
f40e971b90
15 changed files with 95 additions and 293 deletions
|
@ -130,7 +130,7 @@ export default {
|
|||
return this.$store.state.downloads.downloads
|
||||
},
|
||||
mediaScanResults() {
|
||||
return this.$store.state.mediaScanResults
|
||||
return this.$store.state.downloads.mediaScanResults
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
|
@ -156,7 +156,12 @@ export default {
|
|||
|
||||
await this.$localStore.setDownloadFolder(folderObj)
|
||||
|
||||
this.searchFolder()
|
||||
await this.searchFolder()
|
||||
|
||||
var audiobooks = this.$store.state.audiobooks.audiobooks || []
|
||||
if (audiobooks.length) {
|
||||
this.$store.dispatch('downloads/linkOrphanDownloads', audiobooks)
|
||||
}
|
||||
}
|
||||
},
|
||||
async searchFolder() {
|
||||
|
@ -175,7 +180,7 @@ export default {
|
|||
}
|
||||
return sr
|
||||
})
|
||||
this.$store.commit('setMediaScanResults', searchResults)
|
||||
this.$store.commit('downloads/setMediaScanResults', searchResults)
|
||||
} else {
|
||||
this.$toast.warning('No audio or image files found')
|
||||
}
|
||||
|
@ -183,7 +188,7 @@ export default {
|
|||
},
|
||||
async resetFolder() {
|
||||
await this.$localStore.setDownloadFolder(null)
|
||||
this.$store.commit('setMediaScanResults', {})
|
||||
this.$store.commit('downloads/setMediaScanResults', {})
|
||||
this.$toast.info('Unlinked Folder')
|
||||
},
|
||||
jumpToAudiobook(download) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue