Bug 9302: Make the patron search show/hide more links work
authorKyle M Hall <kyle@bywatetsolutions.com>
Wed, 18 Apr 2018 15:06:39 +0000 (11:06 -0400)
committerJonathan Druart <jonathan.druart@bugs.koha-community.org>
Fri, 20 Apr 2018 16:34:41 +0000 (13:34 -0300)
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
koha-tmpl/intranet-tmpl/prog/en/modules/members/merge-patrons.tt

index 354ffbf..8eef1c1 100644 (file)
@@ -1,25 +1,12 @@
+[% USE Asset %]
 [% USE Branches %]
 [% USE Categories %]
 [% USE KohaDates %]
+[% SET footerjs = 1 %]
 [% INCLUDE 'doc-head-open.inc' %]
 <title>Koha &rsaquo; Patrons &rsaquo; Merge patron records</title>
 [% INCLUDE 'doc-head-close.inc' %]
 
-<script type="text/javascript">
-//<![CDATA[
-$(document).ready(function() {
-    $('#merge-patrons').prop('disabled', true);
-    $('#patron-merge-table').on('change', 'input', function() {
-        if ( $('.keeper:checked').length > 0 ) {
-            $('#merge-patrons').prop('disabled', false);
-        } else {
-            $('#merge-patrons').prop('disabled', true);
-        }
-    });
-});
-//]]>
-</script>
-
 </head>
 <body id="pat_merge" class="pat">
 [% INCLUDE 'header.inc' %]
@@ -133,4 +120,22 @@ $(document).ready(function() {
             [% END %]
         </div>
     </div>
+
+[% MACRO jsinclude BLOCK %]
+    [% Asset.js("js/members-menu.js") %]
+
+    <script>
+    $(document).ready(function() {
+        $('#merge-patrons').prop('disabled', true);
+        $('#patron-merge-table').on('change', 'input', function() {
+            if ( $('.keeper:checked').length > 0 ) {
+                $('#merge-patrons').prop('disabled', false);
+            } else {
+                $('#merge-patrons').prop('disabled', true);
+            }
+        });
+    });
+    </script>
+[% END %]
+
 [% INCLUDE 'intranet-bottom.inc' %]