From bc54704cd65b06639a1fbfb222b873f2d2fdd35b Mon Sep 17 00:00:00 2001 From: Andreas Roussos Date: Sun, 7 Oct 2018 21:00:09 +0300 Subject: [PATCH] Bug 21513: Add a 'Cancel' button to the authority editor and remove duplicate 'Save' button The authority editor (authorities/authorities.pl) does not have a 'Cancel' button. Also, it has two 'Save' buttons. This patch fixes that by: a) adding a 'Cancel' button to the floating toolbar at the top b) removing the 'Save' button from the bottom of the page Test plan: 1) Go to Home > Authorities and launch the authority editor by clicking on 'New authority'. Notice how the editor doesn't have a 'Cancel' button. Also notice the two 'Save' buttons. 2) Apply the patch. 3) Re-launch the authority editor, and hit cancel; you should be taken back to Home > Authorities. 4) Edit an existing authority, and hit cancel; you should be taken back to the details page for the authority you chose. 5) Edit an authority as new (duplicate), and hit cancel; you should be taken back to Home > Authorities (this behaviour is mimicking the bibliographic editor: when duplicating a biblio the 'Cancel' button will take you back to Home > Cataloging). Signed-off-by: Michal Denar Signed-off-by: Martin Renvoize Signed-off-by: Nick Clemens (cherry picked from commit 2cffe3a574e14d5f35ce7b1d9ffe28a153dcb37e) Signed-off-by: Martin Renvoize (cherry picked from commit 81ceef6b8410988dbf14ae0db3dfac64ae084fc9) Signed-off-by: Fridolin Somers --- .../prog/en/modules/authorities/authorities.tt | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt index b65e91fdbc..e849f75351 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/authorities/authorities.tt @@ -216,6 +216,13 @@ function confirmnotdup(redirect){ +
+ [% IF ( authid ) %] + Cancel + [% ELSE %] + Cancel + [% END %] +
@@ -426,10 +433,6 @@ function confirmnotdup(redirect){ [% END %] -
- -
-
-- 2.39.5