From 4d15224c78b61e89f22eb44c4819475555808095 Mon Sep 17 00:00:00 2001 From: Nick Clemens Date: Wed, 17 Mar 2021 13:25:44 +0000 Subject: [PATCH] Bug 13613: (Bug 22744 follow-up) Remove js handling for 'none' There was a function and a set of onclick events to handle the 'Do not notify' checkboxes. Those have been removed, so should this code To test: 1 - Sign in to opac 2 - Click on 'your messaging' tab from 'your account' 3 - Check/uncheck some boxes 4 - Note error in the console: Uncaught TypeError: document.opacmessaging.none2 is undefined 5 - Apply patch 6 - repeat 7 - no more error Signed-off-by: Owen Leonard Signed-off-by: Katrin Fischer Signed-off-by: Jonathan Druart --- .../bootstrap/en/modules/opac-messaging.tt | 26 ++++++------------- 1 file changed, 8 insertions(+), 18 deletions(-) diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-messaging.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-messaging.tt index 40ff5283b3..e1faabeac8 100644 --- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-messaging.tt +++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-messaging.tt @@ -106,13 +106,13 @@ class="phone" id="phone[% messaging_preference.message_attribute_id | html %]" name="[% messaging_preference.message_attribute_id | html %]" - value="phone" checked="checked" onclick = "document.opacmessaging.none[% messaging_preference.message_attribute_id | html %].checked=false;" /> + value="phone" checked="checked" /> [% ELSE %] + value="phone" /> [% END %] [% ELSE %] @@ -127,13 +127,13 @@ class="itiva" id="itiva[% messaging_preference.message_attribute_id | html %]" name="[% messaging_preference.message_attribute_id | html %]" - value="itiva" checked="checked" onclick = "document.opacmessaging.none[% messaging_preference.message_attribute_id | html %].checked=false;" /> + value="itiva" checked="checked" /> [% ELSE %] + value="itiva" /> [% END %] [% ELSE %] @@ -144,9 +144,9 @@ [% IF ( messaging_preference.transport_email ) %] [% IF ( messaging_preference.transports_email ) %] - + [% ELSE %] - + [% END %] [% ELSE %] @@ -156,9 +156,9 @@ [% IF ( messaging_preference.has_digest ) %] [% IF ( messaging_preference.digest ) %] - + [% ELSE %] - + [% END %] [% ELSE %] @@ -248,16 +248,6 @@ [% BLOCK jsinclude %]