From 8cd49bcac8e0ece534e8203abeee64a08aa79cf4 Mon Sep 17 00:00:00 2001
From: Owen Leonard
Date: Tue, 17 Mar 2020 18:44:23 +0000
Subject: [PATCH] Bug 16962: Remove the use of "onclick" from serial collection
template
This patch removes the use of event attributes like "onclick" from the
serial collection template. Events are now defined in JavaScript.
To test, apply the patch and go to Serials
- Locate or create a subscription for which an item record is NOT
created when receiving.
- On the serial collection page for this subscription, test that the
"Multi receiving" button works correctly.
- For any subscription, test that the "Generate next" button works
correctly.
- In each tab, test that the "select all" and "clear all" links work
correctly and affect only that tab.
- On a subscription which has expired, test that the "Renew" button
works correctly.
---
.../prog/en/modules/serials/serials-collection.tt | 61 ++++++++++++++--------
1 file changed, 38 insertions(+), 23 deletions(-)
diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/serials-collection.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/serials-collection.tt
index 7d4310d406..a5d301364d 100644
--- a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/serials-collection.tt
+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/serials/serials-collection.tt
@@ -71,12 +71,8 @@
Create routing list
[% END %]
[% END %]
- [% IF ( subscription.abouttoexpire ) %] Renew
- [% ELSE %]
- [% IF ( subscription.subscriptionexpired ) %] Renew
- [% ELSE %]
-
- [% END %]
+ [% IF ( subscription.abouttoexpire || subscription.subscriptionexpired) %]
+ Renew
[% END %]
[% ELSE %]
@@ -114,7 +110,9 @@
[% UNLESS subscription.closed %]
-
+
+
+
[% IF ( subscriptions.size == 1 and !serialsadditems ) %]
[% END %]
@@ -122,10 +120,10 @@