From 93c27467e8b83f36462f904a89ce5b7a56beac85 Mon Sep 17 00:00:00 2001 From: Jonathan Druart Date: Thu, 6 Jul 2023 10:17:20 +0200 Subject: [PATCH] Bug 34215: Introduce a ToolbarButton Vue component Our toolbar component is not flexible enough, we cannot: * have something else than a router-link * have a link outside of the app (it needs to be a Vue route) This patch adds a ToolbarButton component that is used for existing button. But other buttons can be added without being a router-link. Test plan: No change in behaviour here! Test the buttons in the 4 existing toolbar (in the ERM module) Sponsored-by: BULAC - http://www.bulac.fr/ Signed-off-by: Pedro Amorim --- .../js/vue/components/ERM/AgreementsList.vue | 18 ++++++------ .../ERM/EHoldingsLocalPackagesList.vue | 18 ++++++------ .../ERM/EHoldingsLocalTitlesList.vue | 28 +++++++++---------- .../js/vue/components/ERM/LicensesList.vue | 11 ++++++-- .../prog/js/vue/components/Toolbar.vue | 12 +------- .../prog/js/vue/components/ToolbarButton.vue | 27 ++++++++++++++++++ 6 files changed, 69 insertions(+), 45 deletions(-) create mode 100644 koha-tmpl/intranet-tmpl/prog/js/vue/components/ToolbarButton.vue diff --git a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsList.vue b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsList.vue index 20b9b9a82d..a7e595fee0 100644 --- a/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsList.vue +++ b/koha-tmpl/intranet-tmpl/prog/js/vue/components/ERM/AgreementsList.vue @@ -1,7 +1,13 @@