From 60f0aee9b6d3c9e1312521d6e40b76b38006d2e0 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 Signed-off-by: Kyle M Hall Signed-off-by: Tomas Cohen Arazi --- .../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 2d3dabd508..50305dc21a 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 @@