Update: switch to target library view after moving items

This commit is contained in:
Tiberiu Ichim 2026-02-22 17:37:22 +02:00
parent b0280f614b
commit ed48fd8558

View file

@ -210,12 +210,16 @@ export default {
} }
// Clear selection after batch move // Clear selection after batch move
this.$store.commit('globals/resetSelectedMediaItems') this.$store.commit('globals/resetSelectedMediaItems')
if (response.successCount > 0) {
this.$router.push(`/library/${this.selectedLibraryId}`)
}
} else { } else {
// Single item move // Single item move
const response = await this.$axios.$post(`/api/items/${this.libraryItem.id}/move`, payload) const response = await this.$axios.$post(`/api/items/${this.libraryItem.id}/move`, payload)
if (response.success) { if (response.success) {
this.$toast.success(this.$strings.ToastItemMoved) this.$toast.success(this.$strings.ToastItemMoved)
this.$store.commit('setSelectedLibraryItem', null) this.$store.commit('setSelectedLibraryItem', null)
this.$router.push(`/library/${this.selectedLibraryId}`)
} }
} }
this.show = false this.show = false