mirror of
https://github.com/advplyr/audiobookshelf.git
synced 2026-07-11 03:41:42 +00:00
Consolidate translations and reduce number of toasts
This commit is contained in:
parent
3dfbddda33
commit
c273626c3d
18 changed files with 15 additions and 48 deletions
|
|
@ -194,7 +194,6 @@ export default {
|
|||
if (data.error) {
|
||||
this.$toast.error(data.error)
|
||||
} else {
|
||||
this.$toast.success(this.$strings.ToastCoverUploaded)
|
||||
this.resetCoverPreview()
|
||||
}
|
||||
this.processingUpload = false
|
||||
|
|
@ -264,7 +263,6 @@ export default {
|
|||
.$post(`/api/items/${this.libraryItemId}/cover`, { url: cover })
|
||||
.then(() => {
|
||||
this.imageUrl = ''
|
||||
this.$toast.success(this.$strings.ToastCoverUpdateSuccess)
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error('Failed to update cover', error)
|
||||
|
|
@ -308,9 +306,6 @@ export default {
|
|||
this.isProcessing = true
|
||||
this.$axios
|
||||
.$patch(`/api/items/${this.libraryItemId}/cover`, { cover: coverFile.metadata.path })
|
||||
.then(() => {
|
||||
this.$toast.success(this.$strings.ToastCoverUpdateSuccess)
|
||||
})
|
||||
.catch((error) => {
|
||||
console.error('Failed to set local cover', error)
|
||||
this.$toast.error(error.response?.data || this.$strings.ToastCoverUpdateFailed)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue