From d040765ea26126ced01820906873ec952f1b5bcd Mon Sep 17 00:00:00 2001 From: Matt Blenkinsop Date: Fri, 17 Oct 2025 10:25:26 +0100 Subject: [PATCH] Bug 40191: Add configurable post-save navigation for Vue resource forms This patch introduces a new navigation behavior system for resource forms, allowing each resource type to define its default post-save action (stay on form, show detail, or return to list). Changes: - Add `on_save_navigation` prop to ResourceFormSave component - Extend base-resource composable with navigation configuration - Implement navigation logic in ButtonSubmit component - Apply to AgreementResource as initial implementation This provides a more flexible UX by letting different resource types have appropriate default behaviors while maintaining consistent patterns. Signed-off-by: Michaela Signed-off-by: Jan Kissig Signed-off-by: Martin Renvoize --- .../prog/js/vue/components/ButtonSubmit.vue | 7 +----- .../vue/components/ERM/AgreementResource.vue | 22 ++++++++++--------- .../js/vue/components/ResourceFormSave.vue | 22 ++++++++++++++++++- .../js/vue/components/SkeletonResource.vue | 2 ++ .../prog/js/vue/composables/base-resource.js | 1 + 5 files changed, 37 insertions(+), 17 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ButtonSubmit.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ButtonSubmit.vue index 790449be65d..cf91b240149 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ButtonSubmit.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ButtonSubmit.vue @@ -1,16 +1,11 @@