diff --git a/frontend/src/components/AuthorsAddEdit.vue b/frontend/src/components/AuthorsAddEdit.vue index ba93756..06bfb35 100644 --- a/frontend/src/components/AuthorsAddEdit.vue +++ b/frontend/src/components/AuthorsAddEdit.vue @@ -105,6 +105,9 @@ title: this.translate('general').success, text: this.translate('authors').updatedSuccess }) + + // Redirect to authors list + router.push({ name: 'authors' }) }) .catch(e => { this.loading = false @@ -121,15 +124,15 @@ title: this.translate('general').success, text: this.translate('authors').insertedSuccess }) + + // Redirect to authors list + router.push({ name: 'authors' }) }) .catch(e => { this.loading = false this.errorNotification(e) }) } - - // Redirect to books list - router.push({ name: 'authors' }) } } } diff --git a/frontend/src/components/ItemsAddEdit.vue b/frontend/src/components/ItemsAddEdit.vue index d3956f3..ce56528 100644 --- a/frontend/src/components/ItemsAddEdit.vue +++ b/frontend/src/components/ItemsAddEdit.vue @@ -119,6 +119,9 @@ title: this.translate('general').success, text: this.translate('items').updatedSuccess }) + + // Redirect to items list + router.push({ name: 'items' }) }) .catch(e => { this.loading = false @@ -135,15 +138,15 @@ title: this.translate('general').success, text: this.translate('items').insertedSuccess }) + + // Redirect to items list + router.push({ name: 'items' }) }) .catch(e => { this.loading = false this.errorNotification(e) }) } - - // Redirect to books list - router.push({ name: 'items' }) } } } diff --git a/frontend/src/components/PublishersAddEdit.vue b/frontend/src/components/PublishersAddEdit.vue index e8fc3b7..29c8908 100644 --- a/frontend/src/components/PublishersAddEdit.vue +++ b/frontend/src/components/PublishersAddEdit.vue @@ -99,6 +99,9 @@ title: this.translate('general').success, text: this.translate('publishers').updatedSuccess }) + + // Redirect to books list + router.push({ name: 'publishers' }) }) .catch(e => { this.loading = false @@ -115,15 +118,15 @@ title: this.translate('general').success, text: this.translate('publishers').insertedSuccess }) + + // Redirect to books list + router.push({ name: 'publishers' }) }) .catch(e => { this.loading = false this.errorNotification(e) }) } - - // Redirect to books list - router.push({ name: 'publishers' }) } } }