+ [% INCLUDE 'datatables.inc' %]
+ [% INCLUDE 'columns_settings.inc' %]
+ <script>
+ var checkouts_columns = [% TablesSettings.GetColumns( 'circ', 'print_summary', 'print-summary-checkouts', 'json' ) | $raw %];
+ var holds_columns = [% TablesSettings.GetColumns( 'circ', 'print_summary', 'print-summary-holds', 'json' ) | $raw %];
+ var fines_columns = [% TablesSettings.GetColumns( 'circ', 'print_summary', 'print-summary-fines', 'json' ) | $raw %];
+
+ function moveColumnsButton( tableId ){
+ /* Hide the export button */
+ $("#" + tableId + "_wrapper").find("button.export_controls").remove();
+ /* We don't show the table controls toolbar here, so the columns settings button looks better as part of the caption */
+ $("#" + tableId).find("caption").append( $("#" + tableId + "_wrapper").find("button.columns_controls") );
+ }
+
+ $(document).ready(function() {
+
+ KohaTable("print-summary-checkouts", {
+ "dom": "Bt",
+ "paging": "false",
+ initComplete: function( settings) {
+ moveColumnsButton( settings.nTable.id );
+ }
+ }, checkouts_columns);
+
+ KohaTable("print-summary-holds", {
+ "dom": "Bt",
+ "paging": "false",
+ initComplete: function( settings) {
+ moveColumnsButton( settings.nTable.id );
+ }
+ }, holds_columns);
+
+ KohaTable("print-summary-fines", {
+ "dom": "Bt",
+ "paging": "false",
+ initComplete: function( settings) {
+ moveColumnsButton( settings.nTable.id );
+ }
+ }, fines_columns);
+
+ });
+ </script>