View | Details | Raw Unified | Return to bug 26553
Collapse All | Expand All

(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/acqui-home.tt (-2 / +1 lines)
Lines 206-218 Link Here
206
    [% INCLUDE 'datatables.inc' %]
206
    [% INCLUDE 'datatables.inc' %]
207
    [% Asset.js("lib/jquery/plugins/treetable/jquery.treetable.js") | $raw %]
207
    [% Asset.js("lib/jquery/plugins/treetable/jquery.treetable.js") | $raw %]
208
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
208
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
209
    [% INCLUDE 'columns_settings.inc' %]
210
    <script>
209
    <script>
211
        dt_overwrite_html_sorting_localeCompare();
210
        dt_overwrite_html_sorting_localeCompare();
212
211
213
        $(document).ready(function() {
212
        $(document).ready(function() {
214
            var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'acq_acqui-home', 'accounts', 'json' ) | $raw %];
213
            var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'acq_acqui-home', 'accounts', 'json' ) | $raw %];
215
            var oTable = KohaTable("accounts", {
214
            var oTable = $("#accounts").kohaTable({
216
                "drawCallback": function ( oSettings ) {
215
                "drawCallback": function ( oSettings ) {
217
                    if ( oSettings.aiDisplay.length == 0 )
216
                    if ( oSettings.aiDisplay.length == 0 )
218
                    {
217
                    {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/duplicate_orders.tt (-3 / +2 lines)
Lines 312-318 Link Here
312
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
312
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
313
    [% INCLUDE 'calendar.inc' %]
313
    [% INCLUDE 'calendar.inc' %]
314
    [% INCLUDE 'datatables.inc' %]
314
    [% INCLUDE 'datatables.inc' %]
315
    [% INCLUDE 'columns_settings.inc' %]
316
    [% Asset.js("js/acq.js") | $raw %]
315
    [% Asset.js("js/acq.js") | $raw %]
317
    [% Asset.js("js/funds_sorts.js") | $raw %]
316
    [% Asset.js("js/funds_sorts.js") | $raw %]
318
    <script>
317
    <script>
Lines 329-336 Link Here
329
        var MSG_NO_FUND_SELECTED = _("No fund selected.");
328
        var MSG_NO_FUND_SELECTED = _("No fund selected.");
330
        $(document).ready(function() {
329
        $(document).ready(function() {
331
            $('span.hint').hide();
330
            $('span.hint').hide();
332
            KohaTable("table_orders", {
331
            $("#table_orders").kohaTable({
333
                "paginate": false
332
                paginate: false,
334
            });
333
            });
335
334
336
            [% IF op == 'search' OR op == 'select' %]
335
            [% IF op == 'search' OR op == 'select' %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/histsearch.tt (-4 / +6 lines)
Lines 167-180 Link Here
167
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
167
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
168
    [% INCLUDE 'calendar.inc' %]
168
    [% INCLUDE 'calendar.inc' %]
169
    [% INCLUDE 'datatables.inc' %]
169
    [% INCLUDE 'datatables.inc' %]
170
    [% INCLUDE 'columns_settings.inc' %]
171
    <script>
170
    <script>
172
        var MSG_REMOVE_PATRON = _("Remove");
171
        var MSG_REMOVE_PATRON = _("Remove");
173
        $(document).ready(function() {
172
        $(document).ready(function() {
174
            var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'histsearch', 'histsearcht', 'json' ) | $raw %];
173
            var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'histsearch', 'histsearcht', 'json' ) | $raw %];
175
            KohaTable("histsearcht", {
174
            $("#histsearcht").kohaTable(
176
                "pagingType": "full"
175
                {
177
            }, table_settings );
176
                    pagingType: "full",
177
                },
178
                table_settings
179
            );
178
180
179
            function AddPatron( patron_name, value, container, input_name ) {
181
            function AddPatron( patron_name, value, container, input_name ) {
180
                div = "<div id='borrower_" + value + "'>" + patron_name + " ( <a href='#' class='removePatron'><i class='fa fa-trash-can' aria-hidden='true'></i> " + MSG_REMOVE_PATRON + " </a> ) <input type='hidden' name='" + input_name + "' value='" + value + "' /></div>";
182
                div = "<div id='borrower_" + value + "'>" + patron_name + " ( <a href='#' class='removePatron'><i class='fa fa-trash-can' aria-hidden='true'></i> " + MSG_REMOVE_PATRON + " </a> ) <input type='hidden' name='" + input_name + "' value='" + value + "' /></div>";
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/acqui/lateorders.tt (-2 / +1 lines)
Lines 373-379 Link Here
373
[% MACRO jsinclude BLOCK %]
373
[% MACRO jsinclude BLOCK %]
374
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
374
    [% Asset.js("js/acquisitions-menu.js") | $raw %]
375
    [% INCLUDE 'datatables.inc' %]
375
    [% INCLUDE 'datatables.inc' %]
376
    [% INCLUDE 'columns_settings.inc' %]
377
    [% INCLUDE 'calendar.inc' %]
376
    [% INCLUDE 'calendar.inc' %]
378
    <script>
377
    <script>
379
        var late_orderst;
378
        var late_orderst;
Lines 390-396 Link Here
390
        $(document).ready(function() {
389
        $(document).ready(function() {
391
390
392
            var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'lateorders', 'late_orders', 'json' ) | $raw %];
391
            var table_settings = [% TablesSettings.GetTableSettings( 'acqui', 'lateorders', 'late_orders', 'json' ) | $raw %];
393
            late_orderst = KohaTable("late_orders", {
392
            late_orderst = $("#late_orders").kohaTable({
394
                "sorting": [[ 1, "asc" ]],
393
                "sorting": [[ 1, "asc" ]],
395
                "pagingType": "full",
394
                "pagingType": "full",
396
                "autoWidth": false,
395
                "autoWidth": false,
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/aqbudgets.tt (-2 / +1 lines)
Lines 676-687 Link Here
676
        [% PROCESS patron_search_js columns => columns, actions => ["select"], preview_on_name_click => 1, table_id => 'patron_search_modal_owner_table' %]
676
        [% PROCESS patron_search_js columns => columns, actions => ["select"], preview_on_name_click => 1, table_id => 'patron_search_modal_owner_table' %]
677
    [% ELSIF op == 'list' %]
677
    [% ELSIF op == 'list' %]
678
        [% INCLUDE 'datatables.inc' %]
678
        [% INCLUDE 'datatables.inc' %]
679
        [% INCLUDE 'columns_settings.inc' %]
680
        [% Asset.js("lib/jquery/plugins/treetable/jquery.treetable.js") | $raw %]
679
        [% Asset.js("lib/jquery/plugins/treetable/jquery.treetable.js") | $raw %]
681
        <script>
680
        <script>
682
            $(document).ready(function() {
681
            $(document).ready(function() {
683
                [% IF budgets %]
682
                [% IF budgets %]
684
                    var oTable = KohaTable("budgeth", {
683
                    var oTable = $("#budgeth").kohaTable({
685
                        "drawCallback": function ( oSettings ) {
684
                        "drawCallback": function ( oSettings ) {
686
                            if ( oSettings.aiDisplay.length == 0 )
685
                            if ( oSettings.aiDisplay.length == 0 )
687
                            {
686
                            {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/authorised_values.tt (-2 / +1 lines)
Lines 403-412 Link Here
403
[% MACRO jsinclude BLOCK %]
403
[% MACRO jsinclude BLOCK %]
404
    [% Asset.js("js/admin-menu.js") | $raw %]
404
    [% Asset.js("js/admin-menu.js") | $raw %]
405
    [% INCLUDE 'datatables.inc' %]
405
    [% INCLUDE 'datatables.inc' %]
406
    [% INCLUDE 'columns_settings.inc' %]
407
    <script>
406
    <script>
408
        $(document).ready(function () {
407
        $(document).ready(function () {
409
            KohaTable("categoriest", {
408
            $("#categoriest").kohaTable({
410
                order: [[0, "asc"]],
409
                order: [[0, "asc"]],
411
                pagingType: "full",
410
                pagingType: "full",
412
            });
411
            });
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/currency.tt (-4 / +2 lines)
Lines 266-272 Link Here
266
[% MACRO jsinclude BLOCK %]
266
[% MACRO jsinclude BLOCK %]
267
    [% Asset.js("js/admin-menu.js") | $raw %]
267
    [% Asset.js("js/admin-menu.js") | $raw %]
268
    [% INCLUDE 'datatables.inc' %]
268
    [% INCLUDE 'datatables.inc' %]
269
    [% INCLUDE 'columns_settings.inc' %]
270
    <script>
269
    <script>
271
        function check_currency(val) {
270
        function check_currency(val) {
272
            if ( val == 1.0 ) {
271
            if ( val == 1.0 ) {
Lines 280-288 Link Here
280
        }
279
        }
281
280
282
        $(document).ready(function() {
281
        $(document).ready(function() {
283
            columns_settings = [% TablesSettings.GetTableSettings( 'admin', 'currency', 'currencies-table', 'json' ) | $raw %]
282
            let table_settings = [% TablesSettings.GetTableSettings( 'admin', 'currency', 'currencies-table', 'json' ) | $raw %]
284
            var issuest = KohaTable("currencies-table", {
283
            $("#currencies-table").kohaTable({}, table_settings);
285
            }, columns_settings );
286
284
287
            // prevents users to check active with a currency != 1
285
            // prevents users to check active with a currency != 1
288
            $("#rate").keyup(function() {
286
            $("#rate").keyup(function() {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/desks.tt (-2 / +1 lines)
Lines 213-222 Link Here
213
[% MACRO jsinclude BLOCK %]
213
[% MACRO jsinclude BLOCK %]
214
    [% Asset.js("js/admin-menu.js") | $raw %]
214
    [% Asset.js("js/admin-menu.js") | $raw %]
215
    [% INCLUDE 'datatables.inc' %]
215
    [% INCLUDE 'datatables.inc' %]
216
    [% INCLUDE 'columns_settings.inc' %]
217
    <script>
216
    <script>
218
        $(document).ready(function () {
217
        $(document).ready(function () {
219
            KohaTable("table_desks", {
218
            $("#table_desks").kohaTable({
220
                order: [[1, "asc"]],
219
                order: [[1, "asc"]],
221
            });
220
            });
222
        });
221
        });
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/itemtypes.tt (-4 / +6 lines)
Lines 535-541 Link Here
535
    [% Asset.js("js/admin-menu.js") | $raw %]
535
    [% Asset.js("js/admin-menu.js") | $raw %]
536
    [% INCLUDE 'greybox.inc' %]
536
    [% INCLUDE 'greybox.inc' %]
537
    [% INCLUDE 'datatables.inc' %]
537
    [% INCLUDE 'datatables.inc' %]
538
    [% INCLUDE 'columns_settings.inc' %]
539
    <script>
538
    <script>
540
        $(document).ready(function() {
539
        $(document).ready(function() {
541
           var table_settings = [% TablesSettings.GetTableSettings( 'admin', 'itemtypes', 'table_item_type', 'json' ) | $raw %];
540
           var table_settings = [% TablesSettings.GetTableSettings( 'admin', 'itemtypes', 'table_item_type', 'json' ) | $raw %];
Lines 544-552 Link Here
544
           [% END %]
543
           [% END %]
545
544
546
           $(document).ready(function() {
545
           $(document).ready(function() {
547
               KohaTable("table_item_type", {
546
               $("#table_item_type").kohaTable(
548
               "pagingType": "full"
547
                   {
549
               }, table_settings);
548
                       pagingType: "full",
549
                   },
550
                   table_settings
551
               );
550
           });
552
           });
551
553
552
           $( "#itemtypeentry" ).validate({
554
           $( "#itemtypeentry" ).validate({
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/patron-attr-types.tt (-3 / +1 lines)
Lines 406-412 Link Here
406
[% MACRO jsinclude BLOCK %]
406
[% MACRO jsinclude BLOCK %]
407
    [% Asset.js("js/admin-menu.js") | $raw %]
407
    [% Asset.js("js/admin-menu.js") | $raw %]
408
    [% INCLUDE 'datatables.inc' %]
408
    [% INCLUDE 'datatables.inc' %]
409
    [% INCLUDE 'columns_settings.inc' %]
410
    <script>
409
    <script>
411
        $(document).ready(function () {
410
        $(document).ready(function () {
412
            function toggle_search_default() {
411
            function toggle_search_default() {
Lines 460-467 Link Here
460
459
461
            $(".patron_attributes_types").each(function () {
460
            $(".patron_attributes_types").each(function () {
462
                var tableid = $(this).attr("id");
461
                var tableid = $(this).attr("id");
463
                KohaTable(
462
                $(tableid).kohaTable(
464
                    tableid,
465
                    {
463
                    {
466
                        paginate: false,
464
                        paginate: false,
467
                        autoWidth: false,
465
                        autoWidth: false,
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/smart-rules.tt (-2 / +1 lines)
Lines 1426-1436 Link Here
1426
    [% Asset.js("js/admin-menu.js") | $raw %]
1426
    [% Asset.js("js/admin-menu.js") | $raw %]
1427
    [% INCLUDE 'datatables.inc' %]
1427
    [% INCLUDE 'datatables.inc' %]
1428
    [% INCLUDE 'calendar.inc' %]
1428
    [% INCLUDE 'calendar.inc' %]
1429
    [% INCLUDE 'columns_settings.inc' %]
1430
    [% INCLUDE 'format_price.inc' %]
1429
    [% INCLUDE 'format_price.inc' %]
1431
    <script>
1430
    <script>
1432
        $(document).ready(function () {
1431
        $(document).ready(function () {
1433
            KohaTable("default-circulation-rules", {
1432
            $("#default-circulation-rules").kohaTable({
1434
                columnDefs: [
1433
                columnDefs: [
1435
                    { visible: false, targets: [0, 2] },
1434
                    { visible: false, targets: [0, 2] },
1436
                    { orderable: false, targets: ["_all"] },
1435
                    { orderable: false, targets: ["_all"] },
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt (-12 / +17 lines)
Lines 1700-1706 Link Here
1700
</script>
1700
</script>
1701
    [% END %]
1701
    [% END %]
1702
    [% INCLUDE 'datatables.inc' %]
1702
    [% INCLUDE 'datatables.inc' %]
1703
    [% INCLUDE 'columns_settings.inc' %]
1704
    [% INCLUDE 'js-date-format.inc' %]
1703
    [% INCLUDE 'js-date-format.inc' %]
1705
    [% Asset.js("lib/dayjs/plugin/isSameOrAfter.js") | $raw %]
1704
    [% Asset.js("lib/dayjs/plugin/isSameOrAfter.js") | $raw %]
1706
    [% Asset.js("lib/dayjs/plugin/isSameOrBefore.js") | $raw %]
1705
    [% Asset.js("lib/dayjs/plugin/isSameOrBefore.js") | $raw %]
Lines 2072-2083 Link Here
2072
2071
2073
            [% IF Koha.Preference('AcquisitionDetails') %]
2072
            [% IF Koha.Preference('AcquisitionDetails') %]
2074
                var table_settings = [% TablesSettings.GetTableSettings('catalogue', 'detail', 'acquisitiondetails-table', 'json') | $raw %];
2073
                var table_settings = [% TablesSettings.GetTableSettings('catalogue', 'detail', 'acquisitiondetails-table', 'json') | $raw %];
2075
                var acquisitiondetails_table = KohaTable("orders", {
2074
                var acquisitiondetails_table = $("#orders").kohaTable(
2076
                    "dom": 'C<"top pager"ilpfB><"#filter_c">tr<"bottom pager"ip>',
2075
                    {
2077
                    "paginate": false,
2076
                        dom: 'C<"top pager"ilpfB><"#filter_c">tr<"bottom pager"ip>',
2078
                    "autoWidth": false,
2077
                        paginate: false,
2079
                    "order": [[ 4, "desc" ]],
2078
                        autoWidth: false,
2080
                }, table_settings);
2079
                        order: [[4, "desc"]],
2080
                    },
2081
                    table_settings
2082
                );
2081
            [% END %]
2083
            [% END %]
2082
2084
2083
            [% IF suggestions.count %]
2085
            [% IF suggestions.count %]
Lines 2092-2102 Link Here
2092
2094
2093
            [% IF ( reviews ) %]
2095
            [% IF ( reviews ) %]
2094
                var comment_table_settings = [% TablesSettings.GetTableSettings('catalogue', 'detail', 'comments-table', 'json') | $raw %];
2096
                var comment_table_settings = [% TablesSettings.GetTableSettings('catalogue', 'detail', 'comments-table', 'json') | $raw %];
2095
                var comments_table = KohaTable("comments_table", {
2097
                var comments_table = $("#comments_table").kohaTable(
2096
                    "paginate": false,
2098
                    {
2097
                    "autoWidth": false,
2099
                        paginate: false,
2098
                    "order": [[ 2, "desc" ]],
2100
                        autoWidth: false,
2099
                }, comment_table_settings);
2101
                        order: [[2, "desc"]],
2102
                    },
2103
                    comment_table_settings
2104
                );
2100
            [% END %]
2105
            [% END %]
2101
        });
2106
        });
2102
2107
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/issuehistory.tt (-6 / +8 lines)
Lines 127-133 Link Here
127
127
128
[% MACRO jsinclude BLOCK %]
128
[% MACRO jsinclude BLOCK %]
129
    [% INCLUDE 'datatables.inc' %]
129
    [% INCLUDE 'datatables.inc' %]
130
    [% INCLUDE 'columns_settings.inc' %]
131
    <script id="js">
130
    <script id="js">
132
        $(document).ready(function() {
131
        $(document).ready(function() {
133
            var table_settings = [% TablesSettings.GetTableSettings('catalogue', 'detail', 'checkoutshistory-table', 'json') | $raw %];
132
            var table_settings = [% TablesSettings.GetTableSettings('catalogue', 'detail', 'checkoutshistory-table', 'json') | $raw %];
Lines 135-145 Link Here
135
                // Remove the patron column definition
134
                // Remove the patron column definition
136
                table_settings['columns'].splice(0,1);
135
                table_settings['columns'].splice(0,1);
137
            [% END %]
136
            [% END %]
138
            var table = KohaTable("table_issues", {
137
            var table = $("#table_issues").kohaTable(
139
                "dom": 'C<"top pager"ilpfB><"#filter_c">tr<"bottom pager"ip>',
138
                {
140
                "order": [[ 5, "desc" ]],
139
                    dom: 'C<"top pager"ilpfB><"#filter_c">tr<"bottom pager"ip>',
141
                "pagingType": "full_numbers"
140
                    order: [[5, "desc"]],
142
            }, table_settings);
141
                    pagingType: "full_numbers",
142
                },
143
                table_settings
144
            );
143
        });
145
        });
144
    </script>
146
    </script>
145
[% END %]
147
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/itemsearch.tt (-2 / +1 lines)
Lines 375-381 Link Here
375
[% MACRO jsinclude BLOCK %]
375
[% MACRO jsinclude BLOCK %]
376
    [% INCLUDE 'calendar.inc' %]
376
    [% INCLUDE 'calendar.inc' %]
377
    [% INCLUDE 'datatables.inc' %]
377
    [% INCLUDE 'datatables.inc' %]
378
    [% INCLUDE 'columns_settings.inc' %]
379
    [% INCLUDE 'select2.inc' %]
378
    [% INCLUDE 'select2.inc' %]
380
    <script>
379
    <script>
381
        var authorised_values = [% authorised_values_json | $raw %];
380
        var authorised_values = [% authorised_values_json | $raw %];
Lines 644-650 Link Here
644
            };
643
            };
645
644
646
            var table_settings = [% TablesSettings.GetTableSettings( 'catalogue', 'itemsearch', 'results', 'json' ) | $raw %];
645
            var table_settings = [% TablesSettings.GetTableSettings( 'catalogue', 'itemsearch', 'results', 'json' ) | $raw %];
647
            KohaTable('results' , {
646
            $('#results').kohaTable( {
648
                "bKohaColumnsUseNames": true,
647
                "bKohaColumnsUseNames": true,
649
                "destroy": true,
648
                "destroy": true,
650
                "serverSide": true,
649
                "serverSide": true,
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/addbooks.tt (-4 / +6 lines)
Lines 284-290 Link Here
284
284
285
[% MACRO jsinclude BLOCK %]
285
[% MACRO jsinclude BLOCK %]
286
    [% INCLUDE 'datatables.inc' %]
286
    [% INCLUDE 'datatables.inc' %]
287
    [% INCLUDE 'columns_settings.inc' %]
288
    <script>
287
    <script>
289
        $(document).ready(function() {
288
        $(document).ready(function() {
290
            //Set focus to cataloging search
289
            //Set focus to cataloging search
Lines 329-337 Link Here
329
            });
328
            });
330
329
331
            var table_settings = [% TablesSettings.GetTableSettings( 'cataloguing', 'addbooks', 'reservoir-table', 'json' ) | $raw %]
330
            var table_settings = [% TablesSettings.GetTableSettings( 'cataloguing', 'addbooks', 'reservoir-table', 'json' ) | $raw %]
332
            var reservoirt = KohaTable("reservoir-table", {
331
            var reservoirt = $("#reservoir-table").kohaTable(
333
                "pagingType": "simple"
332
                {
334
            }, table_settings );
333
                    pagingType: "simple",
334
                },
335
                table_settings
336
            );
335
        });
337
        });
336
338
337
        /* this function open a popup to search on z3950 server.  */
339
        /* this function open a popup to search on z3950 server.  */
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/cataloguing/z3950_search.tt (-9 / +9 lines)
Lines 272-292 Link Here
272
[% END %]
272
[% END %]
273
273
274
[% MACRO jsinclude BLOCK %]
274
[% MACRO jsinclude BLOCK %]
275
    [% INCLUDE 'columns_settings.inc' %]
276
    [% INCLUDE 'datatables.inc' %]
275
    [% INCLUDE 'datatables.inc' %]
277
    [% INCLUDE 'z3950_search.inc' %]
276
    [% INCLUDE 'z3950_search.inc' %]
278
    [% Asset.js("js/z3950_search.js") | $raw %]
277
    [% Asset.js("js/z3950_search.js") | $raw %]
279
    <script>
278
    <script>
280
        $(document).ready(function(){
279
        $(document).ready(function(){
281
            var table_settings = [% TablesSettings.GetTableSettings( 'cataloguing', 'z3950_search', 'resultst', 'json' ) | $raw %];
280
            var table_settings = [% TablesSettings.GetTableSettings( 'cataloguing', 'z3950_search', 'resultst', 'json' ) | $raw %];
282
            var thetable = KohaTable("resultst", {
281
            var thetable = $("#resultst").kohaTable(
283
                "columnDefs": [
282
                {
284
                    { "targets": [ 1 ], "type": "nsb-nse" },
283
                    columnDefs: [{ targets: [1], type: "nsb-nse" }],
285
                ],
284
                    paginate: false,
286
                "paginate": false,
285
                    searching: false,
287
                "searching": false,
286
                    info: false,
288
                "info": false
287
                },
289
            }, table_settings );
288
                table_settings
289
            );
290
            InitLastAction();
290
            InitLastAction();
291
        });
291
        });
292
292
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/overdue.tt (-5 / +7 lines)
Lines 327-333 Link Here
327
[% MACRO jsinclude BLOCK %]
327
[% MACRO jsinclude BLOCK %]
328
    [% INCLUDE 'calendar.inc' %]
328
    [% INCLUDE 'calendar.inc' %]
329
    [% INCLUDE 'datatables.inc' %]
329
    [% INCLUDE 'datatables.inc' %]
330
    [% INCLUDE 'columns_settings.inc' %]
331
    [% INCLUDE 'select2.inc' %]
330
    [% INCLUDE 'select2.inc' %]
332
    [% INCLUDE 'js-date-format.inc' %]
331
    [% INCLUDE 'js-date-format.inc' %]
333
    [% PROCESS 'modal-claims-js' %]
332
    [% PROCESS 'modal-claims-js' %]
Lines 372-381 Link Here
372
                table_settings['columns'].splice(13, 1);
371
                table_settings['columns'].splice(13, 1);
373
            [% END %]
372
            [% END %]
374
373
375
            KohaTable("overduest", {
374
            $("#overduest").kohaTable(
376
                "pagingType": "full",
375
                {
377
                "autoWidth": false,
376
                    pagingType: "full",
378
            }, table_settings);
377
                    autoWidth: false,
378
                },
379
                table_settings
380
            );
379
381
380
            $("#showall").on("change", function(){
382
            $("#showall").on("change", function(){
381
                update_date_due_filters_visibility();
383
                update_date_due_filters_visibility();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/pendingreserves.tt (-7 / +12 lines)
Lines 292-298 Link Here
292
[% MACRO jsinclude BLOCK %]
292
[% MACRO jsinclude BLOCK %]
293
    [% INCLUDE 'calendar.inc' %]
293
    [% INCLUDE 'calendar.inc' %]
294
    [% INCLUDE 'datatables.inc' %]
294
    [% INCLUDE 'datatables.inc' %]
295
    [% INCLUDE 'columns_settings.inc' %]
296
    <script>
295
    <script>
297
        function get_options(column){
296
        function get_options(column){
298
            let regex = /(<([^>]+)>)/ig; // Remove html tags
297
            let regex = /(<([^>]+)>)/ig; // Remove html tags
Lines 319-330 Link Here
319
318
320
319
321
            var table_settings = [% TablesSettings.GetTableSettings('circ', 'holds', 'holds-to-pull', 'json') | $raw %];
320
            var table_settings = [% TablesSettings.GetTableSettings('circ', 'holds', 'holds-to-pull', 'json') | $raw %];
322
            var holdst = KohaTable("holdst", {
321
            var holdst = $("#holdst").kohaTable(
323
                "pagingType": "full_numbers",
322
                {
324
                "columnDefs": [
323
                    pagingType: "full_numbers",
325
                    { "orderable": false, "searchable":  false, "targets": [ 'NoSort' ] },
324
                    columnDefs: [
326
                ],
325
                        { orderable: false, searchable: false, targets: ["NoSort"] },
327
            }, table_settings, true, null, filters_options);
326
                    ],
327
                },
328
                table_settings,
329
                true,
330
                null,
331
                filters_options
332
            );
328
        });
333
        });
329
    </script>
334
    </script>
330
[% END %]
335
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/reserveratios.tt (-9 / +14 lines)
Lines 214-232 Link Here
214
[% MACRO jsinclude BLOCK %]
214
[% MACRO jsinclude BLOCK %]
215
    [% INCLUDE 'calendar.inc' %]
215
    [% INCLUDE 'calendar.inc' %]
216
    [% INCLUDE 'datatables.inc' %]
216
    [% INCLUDE 'datatables.inc' %]
217
    [% INCLUDE 'columns_settings.inc' %]
218
    <script>
217
    <script>
219
        var table_settings = [% TablesSettings.GetTableSettings( 'circ', 'holdsratios', 'holds-ratios', 'json' ) | $raw %];
218
        var table_settings = [% TablesSettings.GetTableSettings( 'circ', 'holdsratios', 'holds-ratios', 'json' ) | $raw %];
220
         $(document).ready(function() {
219
         $(document).ready(function() {
221
             KohaTable("holds-ratios", {
220
             $("#holds-ratios").kohaTable(
222
                 "order": [ [2,'desc'], [3,'asc'] ],
221
                 {
223
                   "columnDefs": [
222
                     order: [
224
                       { "type": "anti-the", "targets":  [ "anti-the" ] },
223
                         [2, "desc"],
225
                       { "type": "natural", "targets":  [ "natural" ] },
224
                         [3, "asc"],
226
                     ],
225
                     ],
227
                 "pagingType": "full",
226
                     columnDefs: [
228
                 "autoWidth": false
227
                         { type: "anti-the", targets: ["anti-the"] },
229
             }, table_settings);
228
                         { type: "natural", targets: ["natural"] },
229
                     ],
230
                     pagingType: "full",
231
                     autoWidth: false,
232
                 },
233
                 table_settings
234
             );
230
        });
235
        });
231
    </script>
236
    </script>
232
[% END %]
237
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt (-8 / +10 lines)
Lines 1466-1472 Link Here
1466
1466
1467
[% MACRO jsinclude BLOCK %]
1467
[% MACRO jsinclude BLOCK %]
1468
    [% INCLUDE 'datatables.inc' %]
1468
    [% INCLUDE 'datatables.inc' %]
1469
    [% INCLUDE 'columns_settings.inc' %]
1470
    [% INCLUDE 'calendar.inc' %]
1469
    [% INCLUDE 'calendar.inc' %]
1471
    [% Asset.js("js/pages/circulation.js") | $raw %]
1470
    [% Asset.js("js/pages/circulation.js") | $raw %]
1472
    [% Asset.js("js/modal_printer.js") | $raw %]
1471
    [% Asset.js("js/modal_printer.js") | $raw %]
Lines 1527-1539 Link Here
1527
                Dopop('/cgi-bin/koha/recalls/recall_pickup_slip.pl?recall_id=[% recall_id | uri %]');
1526
                Dopop('/cgi-bin/koha/recalls/recall_pickup_slip.pl?recall_id=[% recall_id | uri %]');
1528
            [% END %]
1527
            [% END %]
1529
1528
1530
            var returns_table = KohaTable("checkedintable", {
1529
            var returns_table = $("#checkedintable").kohaTable(
1531
                    "searching":false,
1530
                {
1532
                    "paginate":false,
1531
                    searching: false,
1533
                    "info": false,
1532
                    paginate: false,
1534
                    "ordering":false,
1533
                    info: false,
1535
                    "dom": '<"table_controls"B>rt',
1534
                    ordering: false,
1536
                    }, table_settings);
1535
                    dom: '<"table_controls"B>rt',
1536
                },
1537
                table_settings
1538
            );
1537
1539
1538
            $("#exemptcheck").change(function () {
1540
            $("#exemptcheck").change(function () {
1539
                if (this.checked == true) {
1541
                if (this.checked == true) {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/view_holdsqueue.tt (-6 / +8 lines)
Lines 347-353 Link Here
347
347
348
[% MACRO jsinclude BLOCK %]
348
[% MACRO jsinclude BLOCK %]
349
    [% INCLUDE 'datatables.inc' %]
349
    [% INCLUDE 'datatables.inc' %]
350
    [% INCLUDE 'columns_settings.inc' %]
351
    <script>
350
    <script>
352
        $(document).ready(function() {
351
        $(document).ready(function() {
353
            var holdst;
352
            var holdst;
Lines 366-376 Link Here
366
            $('#holdst thead input').on('change keyup keydown', filterColumn);
365
            $('#holdst thead input').on('change keyup keydown', filterColumn);
367
366
368
            var table_settings = [% TablesSettings.GetTableSettings('circ', 'view_holdsqueue', 'holds-table', 'json') | $raw %];
367
            var table_settings = [% TablesSettings.GetTableSettings('circ', 'view_holdsqueue', 'holds-table', 'json') | $raw %];
369
            var holdst = KohaTable("holdst", {
368
            var holdst = $("#holdst").kohaTable(
370
                "dom": 'B<"clearfix">t',
369
                {
371
                "orderCellsTop":  true,
370
                    dom: 'B<"clearfix">t',
372
                "paginate": false
371
                    orderCellsTop: true,
373
            }, table_settings);
372
                    paginate: false,
373
                },
374
                table_settings
375
            );
374
376
375
        });
377
        });
376
    </script>
378
    </script>
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/waitingreserves.tt (-14 / +21 lines)
Lines 186-192 Link Here
186
186
187
[% MACRO jsinclude BLOCK %]
187
[% MACRO jsinclude BLOCK %]
188
    [% INCLUDE 'datatables.inc' %]
188
    [% INCLUDE 'datatables.inc' %]
189
    [% INCLUDE 'columns_settings.inc' %]
190
    <script>
189
    <script>
191
        var MSG_CANCEL_SELECTED = _("Cancel selected (%s)");
190
        var MSG_CANCEL_SELECTED = _("Cancel selected (%s)");
192
        var holdst_table_settings  = [% TablesSettings.GetTableSettings( 'circ', 'holds_awaiting_pickup', 'holdst',  'json' ) | $raw %];
191
        var holdst_table_settings  = [% TablesSettings.GetTableSettings( 'circ', 'holds_awaiting_pickup', 'holdst',  'json' ) | $raw %];
Lines 194-214 Link Here
194
        var holdscr_table_settings = [% TablesSettings.GetTableSettings( 'circ', 'holds_awaiting_pickup', 'holdscr', 'json' ) | $raw %];
193
        var holdscr_table_settings = [% TablesSettings.GetTableSettings( 'circ', 'holds_awaiting_pickup', 'holdscr', 'json' ) | $raw %];
195
194
196
        $(document).ready(function() {
195
        $(document).ready(function() {
196
            $("#holdst").kohaTable(
197
                {
198
                    pagingType: "full",
199
                    order: [[1, "asc"]],
200
                },
201
                holdst_table_settings
202
            );
197
203
198
            KohaTable("holdst", {
204
            $("#holdso").kohaTable(
199
                "pagingType": "full",
205
                {
200
                "order": [[1, 'asc']]
206
                    pagingType: "full",
201
            }, holdst_table_settings);
207
                    order: [[1, "asc"]],
208
                },
209
                holdso_table_settings
210
            );
202
211
203
            KohaTable("holdso", {
212
            $("#holdscr").kohaTable(
204
                "pagingType": "full",
213
                {
205
                "order": [[1, 'asc']]
214
                    pagingType: "full",
206
            }, holdso_table_settings);
215
                    order: [[1, "asc"]],
207
216
                },
208
            KohaTable("holdscr", {
217
                holdscr_table_settings
209
                "pagingType": "full",
218
            );
210
                "order": [[1, 'asc']]
211
            }, holdscr_table_settings);
212
219
213
            let cancel_link;
220
            let cancel_link;
214
221
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-details.tt (-5 / +7 lines)
Lines 327-333 Link Here
327
327
328
[% MACRO jsinclude BLOCK %]
328
[% MACRO jsinclude BLOCK %]
329
    [% INCLUDE 'datatables.inc' %]
329
    [% INCLUDE 'datatables.inc' %]
330
    [% INCLUDE 'columns_settings.inc' %]
331
    <script>
330
    <script>
332
        var table_settings = [% TablesSettings.GetTableSettings( 'coursereserves', 'reserves', 'course_reserves_table', 'json' ) | $raw %];
331
        var table_settings = [% TablesSettings.GetTableSettings( 'coursereserves', 'reserves', 'course_reserves_table', 'json' ) | $raw %];
333
        $(document).ready(function(){
332
        $(document).ready(function(){
Lines 341-350 Link Here
341
                $('#rm_items').submit();
340
                $('#rm_items').submit();
342
            });
341
            });
343
342
344
            var rtable = KohaTable("course_reserves_table", {
343
            var rtable = $("#course_reserves_table").kohaTable(
345
                "pagingType": "full",
344
                {
346
                "autoWidth": false,
345
                    pagingType: "full",
347
            }, table_settings );
346
                    autoWidth: false,
347
                },
348
                table_settings
349
            );
348
350
349
            $("#course_reserves_table").on( 'click', " .delete_item", function(e){
351
            $("#course_reserves_table").on( 'click', " .delete_item", function(e){
350
                e.preventDefault();
352
                e.preventDefault();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/course_reserves/course-reserves.tt (-5 / +7 lines)
Lines 93-106 Link Here
93
93
94
[% MACRO jsinclude BLOCK %]
94
[% MACRO jsinclude BLOCK %]
95
    [% INCLUDE 'datatables.inc' %]
95
    [% INCLUDE 'datatables.inc' %]
96
    [% INCLUDE 'columns_settings.inc' %]
97
    <script>
96
    <script>
98
        var table_settings = [% TablesSettings.GetTableSettings( 'coursereserves', 'courses', 'course_reserves_table', 'json' ) | $raw %];
97
        var table_settings = [% TablesSettings.GetTableSettings( 'coursereserves', 'courses', 'course_reserves_table', 'json' ) | $raw %];
99
        $(document).ready(function() {
98
        $(document).ready(function() {
100
            var ctable = KohaTable("course_reserves_table", {
99
            var ctable = $("#course_reserves_table").kohaTable(
101
                "pagingType": "full",
100
                {
102
                "autoWidth": false
101
                    pagingType: "full",
103
            }, table_settings );
102
                    autoWidth: false,
103
                },
104
                table_settings
105
            );
104
        });
106
        });
105
    </script>
107
    </script>
106
[% END %]
108
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/boraccount.tt (-6 / +8 lines)
Lines 430-436 Link Here
430
[% MACRO jsinclude BLOCK %]
430
[% MACRO jsinclude BLOCK %]
431
    [% INCLUDE 'datatables.inc' %]
431
    [% INCLUDE 'datatables.inc' %]
432
    [% INCLUDE 'format_price.inc' %]
432
    [% INCLUDE 'format_price.inc' %]
433
    [% INCLUDE 'columns_settings.inc' %]
434
    [% INCLUDE 'str/members-menu.inc' %]
433
    [% INCLUDE 'str/members-menu.inc' %]
435
    [% Asset.js("js/members-menu.js") | $raw %]
434
    [% Asset.js("js/members-menu.js") | $raw %]
436
    <script>
435
    <script>
Lines 442-452 Link Here
442
            var txtActivefilter = _("Filter paid transactions");
441
            var txtActivefilter = _("Filter paid transactions");
443
            var txtInactivefilter = _("Show all transactions");
442
            var txtInactivefilter = _("Show all transactions");
444
            var table_settings = [% TablesSettings.GetTableSettings('members', 'fines', 'account-fines', 'json') | $raw %];
443
            var table_settings = [% TablesSettings.GetTableSettings('members', 'fines', 'account-fines', 'json') | $raw %];
445
            var table_account_fines = KohaTable("table_account_fines", {
444
            var table_account_fines = $("#table_account_fines").kohaTable(
446
                "pagingType": "full",
445
                {
447
                "order": [[0, 'desc']],
446
                    pagingType: "full",
448
                "dom": 'C<"top pager"ilpfB><"#filter_c">tr<"bottom pager"ip>',
447
                    order: [[0, "desc"]],
449
            }, table_settings);
448
                    dom: 'C<"top pager"ilpfB><"#filter_c">tr<"bottom pager"ip>',
449
                },
450
                table_settings
451
            );
450
            $("#filter_c").html('<p><a href="#" id="filter_transacs"><i class="fa fa-filter"></i> '+txtActivefilter+'</a>');
452
            $("#filter_c").html('<p><a href="#" id="filter_transacs"><i class="fa fa-filter"></i> '+txtActivefilter+'</a>');
451
            $('#filter_transacs').click(function(e) {
453
            $('#filter_transacs').click(function(e) {
452
                e.preventDefault();
454
                e.preventDefault();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/holdshistory.tt (-5 / +7 lines)
Lines 121-127 Link Here
121
121
122
[% MACRO jsinclude BLOCK %]
122
[% MACRO jsinclude BLOCK %]
123
    [% INCLUDE 'datatables.inc' %]
123
    [% INCLUDE 'datatables.inc' %]
124
    [% INCLUDE 'columns_settings.inc' %]
125
    [% INCLUDE 'str/members-menu.inc' %]
124
    [% INCLUDE 'str/members-menu.inc' %]
126
    [% Asset.js("js/members-menu.js") | $raw %]
125
    [% Asset.js("js/members-menu.js") | $raw %]
127
    <script>
126
    <script>
Lines 131-140 Link Here
131
              //Remove item type column settings
130
              //Remove item type column settings
132
              table_settings['columns'] = table_settings['columns'].filter(function(c){return c['columnname'] != 'itemtype';});
131
              table_settings['columns'] = table_settings['columns'].filter(function(c){return c['columnname'] != 'itemtype';});
133
            [% END %]
132
            [% END %]
134
            var table = KohaTable("table_holdshistory", {
133
            var table = $("#table_holdshistory").kohaTable(
135
                "pagingType": "full",
134
                {
136
                "order": [[4, 'desc']]
135
                    pagingType: "full",
137
            }, table_settings);
136
                    order: [[4, "desc"]],
137
                },
138
                table_settings
139
            );
138
        });
140
        });
139
    </script>
141
    </script>
140
[% END %]
142
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/housebound.tt (-2 / +1 lines)
Lines 417-430 Link Here
417
[% MACRO jsinclude BLOCK %]
417
[% MACRO jsinclude BLOCK %]
418
    [% INCLUDE 'calendar.inc' %]
418
    [% INCLUDE 'calendar.inc' %]
419
    [% INCLUDE 'datatables.inc' %]
419
    [% INCLUDE 'datatables.inc' %]
420
    [% INCLUDE 'columns_settings.inc' %]
421
    <script>
420
    <script>
422
        $(document).ready(function () {
421
        $(document).ready(function () {
423
            $(".delete").click(function () {
422
            $(".delete").click(function () {
424
                return confirm(_("Are you sure you want to delete this delivery?"));
423
                return confirm(_("Are you sure you want to delete this delivery?"));
425
            });
424
            });
426
        });
425
        });
427
        KohaTable("deliveries", {
426
        $("#deliveries").kohaTable({
428
            pagingType: "full",
427
            pagingType: "full",
429
            autoWidth: false,
428
            autoWidth: false,
430
        });
429
        });
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-print.tt (-16 / +24 lines)
Lines 172-201 Link Here
172
[% MACRO jsinclude BLOCK %]
172
[% MACRO jsinclude BLOCK %]
173
    [% INCLUDE 'slip-print.inc' #printThenClose %]
173
    [% INCLUDE 'slip-print.inc' #printThenClose %]
174
    [% INCLUDE 'datatables.inc' %]
174
    [% INCLUDE 'datatables.inc' %]
175
    [% INCLUDE 'columns_settings.inc' %]
176
    <script>
175
    <script>
177
        var checkouts_columns = [% TablesSettings.GetTableSettings( 'circ', 'print_summary', 'print-summary-checkouts', 'json' ) | $raw %];
176
        var checkouts_columns = [% TablesSettings.GetTableSettings( 'circ', 'print_summary', 'print-summary-checkouts', 'json' ) | $raw %];
178
        var holds_columns = [% TablesSettings.GetTableSettings( 'circ', 'print_summary', 'print-summary-holds', 'json' ) | $raw %];
177
        var holds_columns = [% TablesSettings.GetTableSettings( 'circ', 'print_summary', 'print-summary-holds', 'json' ) | $raw %];
179
        var fines_columns = [% TablesSettings.GetTableSettings( 'circ', 'print_summary', 'print-summary-fines', 'json' ) | $raw %];
178
        var fines_columns = [% TablesSettings.GetTableSettings( 'circ', 'print_summary', 'print-summary-fines', 'json' ) | $raw %];
180
179
181
        function initTables(){
180
        function initTables(){
182
            KohaTable("print-summary-checkouts", {
181
            $("#print-summary-checkouts").kohaTable(
183
                "dom": '<"dt-info"><"top pager"<"table_controls"B>>t',
182
                {
184
                "paging": false,
183
                    dom: '<"dt-info"><"top pager"<"table_controls"B>>t',
185
                "autoWidth": false,
184
                    paging: false,
186
            }, checkouts_columns);
185
                    autoWidth: false,
186
                },
187
                checkouts_columns
188
            );
187
189
188
            KohaTable("print-summary-holds", {
190
            $("#print-summary-holds").kohaTable(
189
                "dom": '<"dt-info"><"top pager"<"table_controls"B>>t',
191
                {
190
                "paging": false,
192
                    dom: '<"dt-info"><"top pager"<"table_controls"B>>t',
191
                "autoWidth": false,
193
                    paging: false,
192
            }, holds_columns);
194
                    autoWidth: false,
195
                },
196
                holds_columns
197
            );
193
198
194
            KohaTable("print-summary-fines", {
199
            $("#print-summary-fines").kohaTable(
195
                "dom": '<"dt-info"><"top pager"<"table_controls"B>>t',
200
                {
196
                "paging": false,
201
                    dom: '<"dt-info"><"top pager"<"table_controls"B>>t',
197
                "autoWidth": false,
202
                    paging: false,
198
            }, fines_columns);
203
                    autoWidth: false,
204
                },
205
                fines_columns
206
            );
199
        }
207
        }
200
208
201
        if( autoprint ){
209
        if( autoprint ){
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/pay.tt (-5 / +7 lines)
Lines 226-232 Link Here
226
    [% INCLUDE 'str/members-menu.inc' %]
226
    [% INCLUDE 'str/members-menu.inc' %]
227
    [% Asset.js("js/members-menu.js") | $raw %]
227
    [% Asset.js("js/members-menu.js") | $raw %]
228
    [% INCLUDE 'datatables.inc' %]
228
    [% INCLUDE 'datatables.inc' %]
229
    [% INCLUDE 'columns_settings.inc' %]
230
    <script>
229
    <script>
231
        function enableCheckboxActions(){
230
        function enableCheckboxActions(){
232
            // Enable/disable controls if checkboxes are checked
231
            // Enable/disable controls if checkboxes are checked
Lines 281-290 Link Here
281
            });
280
            });
282
281
283
            var table_settings = [% TablesSettings.GetTableSettings('members', 'pay', 'pay-fines-table', 'json') | $raw %];
282
            var table_settings = [% TablesSettings.GetTableSettings('members', 'pay', 'pay-fines-table', 'json') | $raw %];
284
            KohaTable("finest", {
283
            $("#finest").kohaTable(
285
                "paging": false,
284
                {
286
                "autoWidth": false
285
                    paging: false,
287
            }, table_settings );
286
                    autoWidth: false,
287
                },
288
                table_settings
289
            );
288
        });
290
        });
289
    </script>
291
    </script>
290
[% END %]
292
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/members/readingrec.tt (-5 / +8 lines)
Lines 160-166 Link Here
160
    [% INCLUDE 'str/members-menu.inc' %]
160
    [% INCLUDE 'str/members-menu.inc' %]
161
    [% Asset.js("js/members-menu.js") | $raw %]
161
    [% Asset.js("js/members-menu.js") | $raw %]
162
    [% INCLUDE 'datatables.inc' %]
162
    [% INCLUDE 'datatables.inc' %]
163
    [% INCLUDE 'columns_settings.inc' %]
164
    [% INCLUDE 'modals/checkout_renewals.inc' %]
163
    [% INCLUDE 'modals/checkout_renewals.inc' %]
165
    [% INCLUDE 'js-date-format.inc' %]
164
    [% INCLUDE 'js-date-format.inc' %]
166
    [% INCLUDE 'js-patron-format.inc' %]
165
    [% INCLUDE 'js-patron-format.inc' %]
Lines 168-182 Link Here
168
    <script id="js">
167
    <script id="js">
169
        $(document).ready(function() {
168
        $(document).ready(function() {
170
            [% IF Koha.Preference('RecordStaffUserOnCheckout') %]
169
            [% IF Koha.Preference('RecordStaffUserOnCheckout') %]
170
                // FIXME This cannot work without bKohaColumnsUseNames
171
                var column_sort = 11;
171
                var column_sort = 11;
172
            [% ELSE %]
172
            [% ELSE %]
173
                var column_sort = 10;
173
                var column_sort = 10;
174
            [% END %]
174
            [% END %]
175
            var table_settings = [% TablesSettings.GetTableSettings('members', 'checkouthistory', 'checkouthistory-table', 'json') | $raw %];
175
            var table_settings = [% TablesSettings.GetTableSettings('members', 'checkouthistory', 'checkouthistory-table', 'json') | $raw %];
176
            var table = KohaTable("table_readingrec", {
176
            var table = $("#table_readingrec").kohaTable(
177
                "pagingType": "full",
177
                {
178
                "order": [[column_sort, 'desc']]
178
                    pagingType: "full",
179
            }, table_settings);
179
                    order: [[column_sort, "desc"]],
180
                },
181
                table_settings
182
            );
180
183
181
            let table_dt = table.DataTable();
184
            let table_dt = table.DataTable();
182
            $("#tabs a[data-bs-toggle='tab']").on("shown.bs.tab", function (e) {
185
            $("#tabs a[data-bs-toggle='tab']").on("shown.bs.tab", function (e) {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/patron_lists/list.tt (-4 / +6 lines)
Lines 6-12 Link Here
6
[% PROCESS 'i18n.inc' %]
6
[% PROCESS 'i18n.inc' %]
7
[% SET footerjs = 1 %]
7
[% SET footerjs = 1 %]
8
[% INCLUDE 'doc-head-open.inc' %]
8
[% INCLUDE 'doc-head-open.inc' %]
9
[% INCLUDE 'columns_settings.inc' %]
10
<title
9
<title
11
    >[% FILTER collapse %]
10
    >[% FILTER collapse %]
12
        [% list.name | html %]
11
        [% list.name | html %]
Lines 241-249 Link Here
241
            $('#patrons_to_add_fieldset').hide();
240
            $('#patrons_to_add_fieldset').hide();
242
241
243
                var table_settings = [% TablesSettings.GetTableSettings('members', 'patron-lists', 'patron-list-table', 'json') | $raw %]
242
                var table_settings = [% TablesSettings.GetTableSettings('members', 'patron-lists', 'patron-list-table', 'json') | $raw %]
244
                KohaTable('patron-list-table', {
243
                $("#patron-list-table").kohaTable(
245
                    "pagingType": "full"
244
                    {
246
                }, table_settings);
245
                        pagingType: "full",
246
                    },
247
                    table_settings
248
                );
247
249
248
            function AddPatron( patron_name, value, container, input_name ) {
250
            function AddPatron( patron_name, value, container, input_name ) {
249
                div = "<div id='borrower_" + value + "'>" + patron_name + " ( <a href='#' class='removePatron'><i class='fa fa-trash-can' aria-hidden='true'></i> " + MSG_REMOVE_PATRON + " </a> ) <input type='hidden' name='" + input_name + "' value='" + value + "' /></div>";
251
                div = "<div id='borrower_" + value + "'>" + patron_name + " ( <a href='#' class='removePatron'><i class='fa fa-trash-can' aria-hidden='true'></i> " + MSG_REMOVE_PATRON + " </a> ) <input type='hidden' name='" + input_name + "' value='" + value + "' /></div>";
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/plugins/plugins-home.tt (-2 / +1 lines)
Lines 301-307 Link Here
301
    [% Asset.js("js/tools-menu.js") | $raw %]
301
    [% Asset.js("js/tools-menu.js") | $raw %]
302
    [% INCLUDE 'calendar.inc' %]
302
    [% INCLUDE 'calendar.inc' %]
303
    [% INCLUDE 'datatables.inc' %]
303
    [% INCLUDE 'datatables.inc' %]
304
    [% INCLUDE 'columns_settings.inc' %]
305
    <script>
304
    <script>
306
        $(document).ready(function () {
305
        $(document).ready(function () {
307
            $(".uninstall_plugin").on("click", function () {
306
            $(".uninstall_plugin").on("click", function () {
Lines 314-320 Link Here
314
                $("#plugin-search-form").submit();
313
                $("#plugin-search-form").submit();
315
            });
314
            });
316
315
317
            KohaTable("installed_plugins", {
316
            $("#installed_plugins").kohaTable({
318
                paginate: false,
317
                paginate: false,
319
            });
318
            });
320
        });
319
        });
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/pos/pay.tt (-6 / +9 lines)
Lines 248-254 Link Here
248
[% MACRO jsinclude BLOCK %]
248
[% MACRO jsinclude BLOCK %]
249
    [% INCLUDE 'format_price.inc' %]
249
    [% INCLUDE 'format_price.inc' %]
250
    [% INCLUDE 'datatables.inc' %]
250
    [% INCLUDE 'datatables.inc' %]
251
    [% INCLUDE 'columns_settings.inc' %]
252
    <script>
251
    <script>
253
        function moneyFormat(textObj) {
252
        function moneyFormat(textObj) {
254
            var newValue = textObj.value;
253
            var newValue = textObj.value;
Lines 437-447 Link Here
437
            });
436
            });
438
437
439
            var items_table_settings = [% TablesSettings.GetTableSettings('pos', 'pay', 'invoices', 'json') | $raw %];
438
            var items_table_settings = [% TablesSettings.GetTableSettings('pos', 'pay', 'invoices', 'json') | $raw %];
440
            var items_table = KohaTable("invoices", {
439
            var items_table = $("#invoices").kohaTable(
441
                   "pagingType": "full",
440
                {
442
                   "order": [[ 0, "asc" ]],
441
                    pagingType: "full",
443
                   "autoWidth": false
442
                    order: [[0, "asc"]],
444
            }, items_table_settings, false);
443
                    autoWidth: false,
444
                },
445
                items_table_settings,
446
                false
447
            );
445
448
446
            $("#invoices").on("click", ".add_button", function(e) {
449
            $("#invoices").on("click", ".add_button", function(e) {
447
                e.preventDefault();
450
                e.preventDefault();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/catalogue_stats.tt (-5 / +8 lines)
Lines 341-347 Link Here
341
[% MACRO jsinclude BLOCK %]
341
[% MACRO jsinclude BLOCK %]
342
    [% INCLUDE 'calendar.inc' %]
342
    [% INCLUDE 'calendar.inc' %]
343
    [% INCLUDE 'datatables.inc' %]
343
    [% INCLUDE 'datatables.inc' %]
344
    [% INCLUDE 'columns_settings.inc' %]
345
    <script>
344
    <script>
346
        function changeRemovedDateTrStatus() {
345
        function changeRemovedDateTrStatus() {
347
            var Cellvalue = $("input[name='Cellvalue']:checked").val();
346
            var Cellvalue = $("input[name='Cellvalue']:checked").val();
Lines 365-370 Link Here
365
            });
364
            });
366
            changeRemovedDateTrStatus();
365
            changeRemovedDateTrStatus();
367
366
367
            // FIXME This does not work, we need to pass table settings, not the columns
368
            columns_settings = [% FILTER collapse %]
368
            columns_settings = [% FILTER collapse %]
369
                [
369
                [
370
                    {
370
                    {
Lines 390-399 Link Here
390
                ];
390
                ];
391
            [% END %]
391
            [% END %]
392
392
393
            var catalogue_stats = KohaTable("catalogue_stats", {
393
            var catalogue_stats = $("#catalogue_stats").kohaTable(
394
                'autoWidth': false,
394
                {
395
                'paging': false,
395
                    autoWidth: false,
396
            }, columns_settings );
396
                    paging: false,
397
                },
398
                columns_settings
399
            );
397
        });
400
        });
398
    </script>
401
    </script>
399
[% END %]
402
[% END %]
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/guided_reports_start.tt (-9 / +10 lines)
Lines 1699-1705 Link Here
1699
    [% INCLUDE 'calendar.inc' %]
1699
    [% INCLUDE 'calendar.inc' %]
1700
    [% INCLUDE 'datatables.inc' %]
1700
    [% INCLUDE 'datatables.inc' %]
1701
    [% IF ( saved1 ) %]
1701
    [% IF ( saved1 ) %]
1702
        [% INCLUDE 'columns_settings.inc' %]
1703
        [% Asset.js( "lib/jsdiff/jsdiff.min.js" ) | $raw %]
1702
        [% Asset.js( "lib/jsdiff/jsdiff.min.js" ) | $raw %]
1704
    [% END %]
1703
    [% END %]
1705
    [% Asset.js( "lib/codemirror/codemirror.min.js" ) | $raw %]
1704
    [% Asset.js( "lib/codemirror/codemirror.min.js" ) | $raw %]
Lines 2153-2167 Link Here
2153
2152
2154
            [% IF (saved1) %]
2153
            [% IF (saved1) %]
2155
                var table_settings = [% TablesSettings.GetTableSettings( 'reports', 'saved-sql', 'table_reports', 'json' ) | $raw %];
2154
                var table_settings = [% TablesSettings.GetTableSettings( 'reports', 'saved-sql', 'table_reports', 'json' ) | $raw %];
2156
                var rtable = KohaTable("table_reports", {
2155
                var rtable = $("#table_reports").kohaTable(
2157
                    "autoWidth": false,
2156
                    {
2158
                    "pagingType": 'full',
2157
                        autoWidth: false,
2159
                    "order": [[ 1, "asc" ]],
2158
                        pagingType: "full",
2160
                    "language": {
2159
                        order: [[1, "asc"]],
2161
                        "zeroRecords": _("No matching reports found")
2160
                        language: {
2161
                            zeroRecords: _("No matching reports found"),
2162
                        },
2162
                    },
2163
                    },
2163
2164
                    table_settings
2164
                }, table_settings);
2165
                );
2165
                let table_dt = rtable.DataTable();
2166
                let table_dt = rtable.DataTable();
2166
2167
2167
                $("#tabs a[data-bs-toggle='tab']").on("shown.bs.tab", function (e) {
2168
                $("#tabs a[data-bs-toggle='tab']").on("shown.bs.tab", function (e) {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/itemslost.tt (-9 / +13 lines)
Lines 193-215 Link Here
193
193
194
[% MACRO jsinclude BLOCK %]
194
[% MACRO jsinclude BLOCK %]
195
    [% INCLUDE 'datatables.inc' %]
195
    [% INCLUDE 'datatables.inc' %]
196
    [% INCLUDE 'columns_settings.inc' %]
197
    <script>
196
    <script>
198
        $(document).ready(function() {
197
        $(document).ready(function() {
199
            var table_settings = [% TablesSettings.GetTableSettings( 'reports', 'lostitems', 'lostitems-table', 'json' ) | $raw %];
198
            var table_settings = [% TablesSettings.GetTableSettings( 'reports', 'lostitems', 'lostitems-table', 'json' ) | $raw %];
200
            [% IF csv_profiles.count %]
199
            [% IF csv_profiles.count %]
201
                // Add the first (checkbox) column if it is displayed
200
                // Add the first (checkbox) column if it is displayed
201
                // FIXME This cannot work without bKohaColumnsUseNames
202
                table_settings['columns'].unshift({cannot_be_modified: 1, cannot_be_toggled: 1, columnname: 'itemnumber', is_hidden: 0});
202
                table_settings['columns'].unshift({cannot_be_modified: 1, cannot_be_toggled: 1, columnname: 'itemnumber', is_hidden: 0});
203
            [% END %]
203
            [% END %]
204
204
205
            var lostitems_table = KohaTable("lostitems-table", {
205
            var lostitems_table = $("#lostitems-table").kohaTable(
206
                "order": [],
206
                {
207
                "columnDefs": [
207
                    order: [],
208
                    { "orderable": false, "searchable":  false, "targets": [ 'NoSort' ] }
208
                    columnDefs: [
209
                ],
209
                        { orderable: false, searchable: false, targets: ["NoSort"] },
210
                "autoWidth": false,
210
                    ],
211
                "paginate": false,
211
                    autoWidth: false,
212
            }, table_settings, 'with_filters');
212
                    paginate: false,
213
                },
214
                table_settings,
215
                "with_filters"
216
            );
213
217
214
            function itemSelectionBuildExportLink() {
218
            function itemSelectionBuildExportLink() {
215
                var itemnumbers = new Array();
219
                var itemnumbers = new Array();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reports/orders_by_budget.tt (-4 / +6 lines)
Lines 168-180 Link Here
168
168
169
[% MACRO jsinclude BLOCK %]
169
[% MACRO jsinclude BLOCK %]
170
    [% INCLUDE 'datatables.inc' %]
170
    [% INCLUDE 'datatables.inc' %]
171
    [% INCLUDE 'columns_settings.inc' %]
172
    <script>
171
    <script>
173
        var table_settings = [% TablesSettings.GetTableSettings( 'reports', 'orders_by_fund', 'funds-table', 'json' ) | $raw %];
172
        var table_settings = [% TablesSettings.GetTableSettings( 'reports', 'orders_by_fund', 'funds-table', 'json' ) | $raw %];
174
        $(document).ready( function () {
173
        $(document).ready( function () {
175
            var funds_table = KohaTable("funds", {
174
            var funds_table = $("#funds").kohaTable(
176
                'autoWidth': false,
175
                {
177
            }, table_settings );
176
                    autoWidth: false,
177
                },
178
                table_settings
179
            );
178
180
179
            showallbudgets = $('#budgetfilter').html();
181
            showallbudgets = $('#budgetfilter').html();
180
            $('#budgetfilter .b_inactive').remove();
182
            $('#budgetfilter .b_inactive').remove();
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/reserve/request.tt (-5 / +7 lines)
Lines 1423-1429 Link Here
1423
[% MACRO jsinclude BLOCK %]
1423
[% MACRO jsinclude BLOCK %]
1424
    [% INCLUDE 'datatables.inc' %]
1424
    [% INCLUDE 'datatables.inc' %]
1425
    [% INCLUDE 'calendar.inc' %]
1425
    [% INCLUDE 'calendar.inc' %]
1426
    [% INCLUDE 'columns_settings.inc' %]
1427
    [% INCLUDE 'select2.inc' %]
1426
    [% INCLUDE 'select2.inc' %]
1428
    [% Asset.js("js/holds.js") | $raw %]
1427
    [% Asset.js("js/holds.js") | $raw %]
1429
    [% Asset.js("js/form-submit.js") | $raw %]
1428
    [% Asset.js("js/form-submit.js") | $raw %]
Lines 1435-1444 Link Here
1435
    <script>
1434
    <script>
1436
        $(document).ready(function () {
1435
        $(document).ready(function () {
1437
            hold_table_settings = [% TablesSettings.GetTableSettings( 'circ', 'holds', 'patron_holds_table', 'json' ) | $raw %];
1436
            hold_table_settings = [% TablesSettings.GetTableSettings( 'circ', 'holds', 'patron_holds_table', 'json' ) | $raw %];
1438
            KohaTable("patron_holds_table", {
1437
            $("#patron_holds_table").kohaTable(
1439
                "bPaginate":false,
1438
                {
1440
                "bKohaColumnsUseNames": true,
1439
                    bPaginate: false,
1441
           }, hold_table_settings);
1440
                    bKohaColumnsUseNames: true,
1441
                },
1442
                hold_table_settings
1443
            );
1442
        });
1444
        });
1443
        var biblionumbers = [[% biblionumbers.join(', ') | $raw %]];
1445
        var biblionumbers = [[% biblionumbers.join(', ') | $raw %]];
1444
        var borrowernumber = "[% patron.borrowernumber | $raw %]";
1446
        var borrowernumber = "[% patron.borrowernumber | $raw %]";
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/serials/subscription-detail.tt (-11 / +12 lines)
Lines 454-460 Link Here
454
    [% Asset.js("js/mana.js") | $raw %]
454
    [% Asset.js("js/mana.js") | $raw %]
455
    [% INCLUDE 'datatables.inc' %]
455
    [% INCLUDE 'datatables.inc' %]
456
    [% Asset.js("lib/jquery/plugins/treetable/jquery.treetable.js") | $raw %]
456
    [% Asset.js("lib/jquery/plugins/treetable/jquery.treetable.js") | $raw %]
457
    [% INCLUDE 'columns_settings.inc' %]
458
    <script>
457
    <script>
459
        // the english words used in display purposes
458
        // the english words used in display purposes
460
        var text = new Array(_("Number"),_("Volume"),_("Issue"),_("Month"),_("Week"),_("Starting with:"),_("Rollover at:"),_("Choose hemisphere:"),_("Northern"),_("Southern",
459
        var text = new Array(_("Number"),_("Volume"),_("Issue"),_("Month"),_("Week"),_("Starting with:"),_("Rollover at:"),_("Choose hemisphere:"),_("Northern"),_("Southern",
Lines 467-482 Link Here
467
            })
466
            })
468
467
469
            var table_settings = [% TablesSettings.GetTableSettings( 'serials', 'subscription-detail', 'orders', 'json' ) | $raw %];
468
            var table_settings = [% TablesSettings.GetTableSettings( 'serials', 'subscription-detail', 'orders', 'json' ) | $raw %];
470
            var table = KohaTable("orders", {
469
            var table = $("#orders").kohaTable(
471
                "columnDefs": [
470
                {
472
                    { "visible": false, "targets": [ 'NoVisible' ] },
471
                    columnDefs: [
473
                    { "orderable": false, "targets": ["_all"] },
472
                        { visible: false, targets: ["NoVisible"] },
474
                ],
473
                        { orderable: false, targets: ["_all"] },
475
474
                    ],
476
                "paginate": false,
475
                    paginate: false,
477
                "autoWidth": false,
476
                    autoWidth: false,
478
                "ordering": false,
477
                    ordering: false,
479
            }, table_settings);
478
                },
479
                table_settings
480
            );
480
481
481
            [% IF orders_grouped.size %]
482
            [% IF orders_grouped.size %]
482
                $(table).treetable({
483
                $(table).treetable({
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/suggestion/suggestion.tt (-6 / +8 lines)
Lines 716-722 Link Here
716
                            [% SWITCH m.code %]
716
                            [% SWITCH m.code %]
717
                            [% CASE 'already_exists' %]
717
                            [% CASE 'already_exists' %]
718
                                <span
718
                                <span
719
                                    >The suggestion has not been added. A suggestion with this title already exists (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% m.id | uri %]&op=show">suggestion #[% m.id | html %]</a
719
                                    >The suggestion has not been added. A suggestion with this title already exists (<a href="/cgi-bin/koha/suggestion/suggestion.pl?suggestionid=[% m.id | html %]&op=show">suggestion #[% m.id | html %]</a
720
                                    >)</span
720
                                    >)</span
721
                                >
721
                                >
722
                            [% CASE 'biblio_exists' %]
722
                            [% CASE 'biblio_exists' %]
Lines 1445-1451 Link Here
1445
    [% END %]
1445
    [% END %]
1446
    [% IF op == 'else' %]
1446
    [% IF op == 'else' %]
1447
        [% INCLUDE 'datatables.inc' %]
1447
        [% INCLUDE 'datatables.inc' %]
1448
        [% INCLUDE 'columns_settings.inc' %]
1449
        <script>
1448
        <script>
1450
            $(document).ready(function() {
1449
            $(document).ready(function() {
1451
                if( $("#suggestiontabs .tab-pane.active").length < 1 ){
1450
                if( $("#suggestiontabs .tab-pane.active").length < 1 ){
Lines 1456-1465 Link Here
1456
1455
1457
                [% FOREACH suggestion IN suggestions %]
1456
                [% FOREACH suggestion IN suggestions %]
1458
                    [% IF suggestion.suggestions.size %]
1457
                    [% IF suggestion.suggestions.size %]
1459
                        KohaTable("table_[% suggestion.suggestiontype | html %]", {
1458
                        $("#table_[% suggestion.suggestiontype | html %]").kohaTable(
1460
                            "sorting": [[ 4, "asc" ]],
1459
                            {
1461
                            "autoWidth": false,
1460
                                sorting: [[4, "asc"]],
1462
                        }, table_settings );
1461
                                autoWidth: false,
1462
                            },
1463
                            table_settings
1464
                        );
1463
                    [% END %]
1465
                    [% END %]
1464
                [% END %]
1466
                [% END %]
1465
1467
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/inventory.tt (-2 / +1 lines)
Lines 407-413 Link Here
407
[% MACRO jsinclude BLOCK %]
407
[% MACRO jsinclude BLOCK %]
408
    [% INCLUDE 'datatables.inc' %]
408
    [% INCLUDE 'datatables.inc' %]
409
    [% INCLUDE 'calendar.inc' %]
409
    [% INCLUDE 'calendar.inc' %]
410
    [% INCLUDE 'columns_settings.inc' %]
411
    <script>
410
    <script>
412
        function checkForm() {
411
        function checkForm() {
413
            if ( $('#uploadbarcodes').val() && $('#barcodelist').val() ) {
412
            if ( $('#uploadbarcodes').val() && $('#barcodelist').val() ) {
Lines 461-467 Link Here
461
460
462
        $(document).ready(function(){
461
        $(document).ready(function(){
463
            var table_settings = [% TablesSettings.GetTableSettings( 'tools', 'inventory', 'inventoryt', 'json' ) | $raw %];
462
            var table_settings = [% TablesSettings.GetTableSettings( 'tools', 'inventory', 'inventoryt', 'json' ) | $raw %];
464
            inventorydt = KohaTable("inventoryt", {
463
            inventorydt = $("#inventoryt").kohaTable({
465
                "pagingType": 'full_numbers',
464
                "pagingType": 'full_numbers',
466
                [% IF compareinv2barcd %]
465
                [% IF compareinv2barcd %]
467
                    // sort on callnumber
466
                    // sort on callnumber
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/modborrowers.tt (-5 / +7 lines)
Lines 483-489 Link Here
483
[% MACRO jsinclude BLOCK %]
483
[% MACRO jsinclude BLOCK %]
484
    [% INCLUDE 'calendar.inc' %]
484
    [% INCLUDE 'calendar.inc' %]
485
    [% INCLUDE 'datatables.inc' %]
485
    [% INCLUDE 'datatables.inc' %]
486
    [% INCLUDE 'columns_settings.inc' %]
487
    [% Asset.js("js/tools-menu.js") | $raw %]
486
    [% Asset.js("js/tools-menu.js") | $raw %]
488
    [% Asset.js("js/members-patron-selections.js") | $raw %]
487
    [% Asset.js("js/members-patron-selections.js") | $raw %]
489
    <script>
488
    <script>
Lines 501-510 Link Here
501
        [% END %]
500
        [% END %]
502
        $(document).ready(function() {
501
        $(document).ready(function() {
503
            [% IF borrowers %]
502
            [% IF borrowers %]
504
                let patron_table = KohaTable("borrowerst", {
503
                let patron_table = $("#borrowerst").kohaTable(
505
                    "order": [[ 1, "asc" ]],
504
                    {
506
                    "autoWidth": true,
505
                        order: [[1, "asc"]],
507
                }, table_settings);
506
                        autoWidth: true,
507
                    },
508
                    table_settings
509
                );
508
510
509
                $("#selectallbutton").click(function() {
511
                $("#selectallbutton").click(function() {
510
                    $("#borrowerst").find("input:checkbox").each(function() {
512
                    $("#borrowerst").find("input:checkbox").each(function() {
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/upload.tt (-3 / +1 lines)
Lines 360-366 Link Here
360
    [% Asset.js("js/tools-menu.js") | $raw %]
360
    [% Asset.js("js/tools-menu.js") | $raw %]
361
    [% INCLUDE 'datatables.inc' %]
361
    [% INCLUDE 'datatables.inc' %]
362
    [% Asset.js("js/file-upload.js") | $raw %]
362
    [% Asset.js("js/file-upload.js") | $raw %]
363
    [% INCLUDE 'columns_settings.inc' %]
364
    <script>
363
    <script>
365
        function StartUpload() {
364
        function StartUpload() {
366
            if( $('#fileToUpload').prop('files').length == 0 ) return;
365
            if( $('#fileToUpload').prop('files').length == 0 ) return;
Lines 493-500 Link Here
493
            table_settings['columns'].splice(5, 1);
492
            table_settings['columns'].splice(5, 1);
494
        [% END %]
493
        [% END %]
495
        $(document).ready(function() {
494
        $(document).ready(function() {
496
            KohaTable("uploadresults",{
495
            $("#uploadresults").kohaTable({}, table_settings);
497
            }, table_settings);
498
496
499
            [% IF msg %]
497
            [% IF msg %]
500
                ShowAlerts( [% msg | html %] );
498
                ShowAlerts( [% msg | html %] );
(-)a/koha-tmpl/intranet-tmpl/prog/js/cataloging_additem.js (-3 / +2 lines)
Lines 1-4 Link Here
1
/* global KOHA searchid biblionumber frameworkcode popup op LABEL_EDIT_ITEM LABEL_DELETE_ITEM MSG_FORM_NOT_SUBMITTED MSG_MANDATORY_FIELDS_EMPTY MSG_ADD_MULTIPLE_ITEMS MSG_ENTER_NUM_ITEMS MSG_CONFIRM_DELETE_ITEM MSG_CONFIRM_ADD_ITEM columns_settings CheckMandatorySubfields CheckMultipleAdd */
1
/* global KOHA searchid biblionumber frameworkcode popup op LABEL_EDIT_ITEM LABEL_DELETE_ITEM MSG_FORM_NOT_SUBMITTED MSG_MANDATORY_FIELDS_EMPTY MSG_ADD_MULTIPLE_ITEMS MSG_ENTER_NUM_ITEMS MSG_CONFIRM_DELETE_ITEM MSG_CONFIRM_ADD_ITEM table_settings CheckMandatorySubfields CheckMultipleAdd */
2
2
3
var browser = KOHA.browser(searchid, parseInt(biblionumber, 10));
3
var browser = KOHA.browser(searchid, parseInt(biblionumber, 10));
4
browser.show();
4
browser.show();
Lines 58-65 $(document).ready(function () { Link Here
58
    // Skip the first column
58
    // Skip the first column
59
    table_settings["columns"].unshift({ cannot_be_toggled: "1" });
59
    table_settings["columns"].unshift({ cannot_be_toggled: "1" });
60
60
61
    var itemst = KohaTable(
61
    var itemst = $("#itemst").kohaTable(
62
        "itemst",
63
        {
62
        {
64
            paging: false,
63
            paging: false,
65
            info: false,
64
            info: false,
(-)a/koha-tmpl/intranet-tmpl/prog/js/categories.js (-2 / +1 lines)
Lines 33-40 jQuery.validator.addMethod( Link Here
33
);
33
);
34
34
35
$(document).ready(function () {
35
$(document).ready(function () {
36
    KohaTable(
36
    $("#patron_categories").kohaTable(
37
        "patron_categories",
38
        {
37
        {
39
            columnDefs: [
38
            columnDefs: [
40
                {
39
                {
(-)a/koha-tmpl/intranet-tmpl/prog/js/checkouts.js (-4 / +2 lines)
Lines 54-61 function LoadIssuesTable() { Link Here
54
            c => c.columnname == "export"
54
            c => c.columnname == "export"
55
        ).is_hidden = 1;
55
        ).is_hidden = 1;
56
    }
56
    }
57
    issuesTable = KohaTable(
57
    issuesTable = $("#issues-table").kohaTable(
58
        "issues-table",
59
        {
58
        {
60
            language: {
59
            language: {
61
                emptyTable: msg_loading,
60
                emptyTable: msg_loading,
Lines 1089-1096 $(document).ready(function () { Link Here
1089
    var relativesIssuesTable;
1088
    var relativesIssuesTable;
1090
    $("#relatives-issues-tab").click(function () {
1089
    $("#relatives-issues-tab").click(function () {
1091
        if (!relativesIssuesTable) {
1090
        if (!relativesIssuesTable) {
1092
            relativesIssuesTable = KohaTable(
1091
            relativesIssuesTable = $("#relatives-issues-table").kohaTable(
1093
                "relatives-issues-table",
1094
                {
1092
                {
1095
                    autoWidth: false,
1093
                    autoWidth: false,
1096
                    dom: '<"table_controls"B>rt',
1094
                    dom: '<"table_controls"B>rt',
(-)a/koha-tmpl/intranet-tmpl/prog/js/holds.js (-2 / +1 lines)
Lines 143-150 $(document).ready(function () { Link Here
143
        var holds = new Array();
143
        var holds = new Array();
144
        if (!holdsTable) {
144
        if (!holdsTable) {
145
            var title;
145
            var title;
146
            holdsTable = KohaTable(
146
            holdsTable = $("#holds-table").kohaTable(
147
                "holds-table",
148
                {
147
                {
149
                    autoWidth: false,
148
                    autoWidth: false,
150
                    dom: '<"table_controls"B>rt',
149
                    dom: '<"table_controls"B>rt',
(-)a/koha-tmpl/intranet-tmpl/prog/js/ill-availability.js (-1 / +1 lines)
Lines 248-254 $(document).ready(function () { Link Here
248
                    .find(".dt-paging");
248
                    .find(".dt-paging");
249
                pagination.toggle(this.api().page.info().pages > 1);
249
                pagination.toggle(this.api().page.info().pages > 1);
250
            };
250
            };
251
            KohaTable(service.id, tableDef, table_settings);
251
            $("#" + service.id).kohaTable(tableDef, table_settings);
252
        });
252
        });
253
    };
253
    };
254
});
254
});
(-)a/koha-tmpl/intranet-tmpl/prog/js/ill-batch-modal.js (-1 / +1 lines)
Lines 1003-1009 Link Here
1003
    }
1003
    }
1004
1004
1005
    function buildTable(identifiers) {
1005
    function buildTable(identifiers) {
1006
        table = KohaTable("identifier-table", {
1006
        table = $("#identifier-table").kohaTable({
1007
            processing: true,
1007
            processing: true,
1008
            ordering: false,
1008
            ordering: false,
1009
            paging: false,
1009
            paging: false,
(-)a/koha-tmpl/intranet-tmpl/prog/js/ill-batch-table.js (-2 / +1 lines)
Lines 45-53 Link Here
45
    }
45
    }
46
46
47
    // Initialise the Datatable
47
    // Initialise the Datatable
48
    // FIXME: This should be a kohaTable not KohaTable
49
    var initTable = function () {
48
    var initTable = function () {
50
        return KohaTable("ill-batch-requests", {
49
        return $("#ill-batch-requests").kohaTable({
51
            data: batchesProxy.data,
50
            data: batchesProxy.data,
52
            columns: [
51
            columns: [
53
                {
52
                {
(-)a/koha-tmpl/intranet-tmpl/prog/js/letter.js (-3 / +2 lines)
Lines 1-5 Link Here
1
/* Variables defined in letter.tt: */
1
/* Variables defined in letter.tt: */
2
/* global _ module add_form copy_form no_op_set code interface theme KohaTable table_settings */
2
/* global _ module add_form copy_form no_op_set code interface theme kohaTable table_settings */
3
3
4
var modal_loading =
4
var modal_loading =
5
    '<div id="loading"><img src="' +
5
    '<div id="loading"><img src="' +
Lines 82-89 function confirmFormatOverwrite(event) { Link Here
82
}
82
}
83
83
84
$(document).ready(function () {
84
$(document).ready(function () {
85
    var ntable = KohaTable(
85
    var ntable = $("#lettert").kohaTable(
86
        "lettert",
87
        {
86
        {
88
            autoWidth: false,
87
            autoWidth: false,
89
            paging: false,
88
            paging: false,
(-)a/koha-tmpl/intranet-tmpl/prog/js/marc_modification_templates.js (-2 / +2 lines)
Lines 1-4 Link Here
1
/* global __ KohaTable table_settings */
1
/* global __ kohaTable table_settings */
2
$(document).ready(function () {
2
$(document).ready(function () {
3
    window.modaction_legend_innerhtml = $("#modaction_legend").text();
3
    window.modaction_legend_innerhtml = $("#modaction_legend").text();
4
    window.action_submit_value = $("#action_submit").val();
4
    window.action_submit_value = $("#action_submit").val();
Lines 139-145 $(document).ready(function () { Link Here
139
        updateAllEvery();
139
        updateAllEvery();
140
    });
140
    });
141
141
142
    KohaTable("templatest", {}, table_settings);
142
    $("#templatest").kohaTable({}, table_settings);
143
143
144
    $(".confirm-delete-action").on("click", function () {
144
    $(".confirm-delete-action").on("click", function () {
145
        return confirm(
145
        return confirm(
(-)a/koha-tmpl/intranet-tmpl/prog/js/pages/batchMod.js (-2 / +2 lines)
Lines 1-4 Link Here
1
/* global KohaTable allColumns Cookies */
1
/* global kohaTable allColumns Cookies */
2
// Set expiration date for cookies
2
// Set expiration date for cookies
3
var date = new Date();
3
var date = new Date();
4
date.setTime(date.getTime() + 365 * 24 * 60 * 60 * 1000);
4
date.setTime(date.getTime() + 365 * 24 * 60 * 60 * 1000);
Lines 170-176 function hideAllColumns() { Link Here
170
}
170
}
171
171
172
$(document).ready(function () {
172
$(document).ready(function () {
173
    var items_table = KohaTable("itemst", {
173
    var items_table = $("#itemst").kohaTable({
174
        columnDefs: [
174
        columnDefs: [
175
            { targets: [0, 1], orderable: false, searchable: true },
175
            { targets: [0, 1], orderable: false, searchable: true },
176
            { targets: [0], visible: false },
176
            { targets: [0], visible: false },
(-)a/koha-tmpl/intranet-tmpl/prog/js/pages/stockrotation.js (-5 / +3 lines)
Lines 1-4 Link Here
1
/* global KohaTable columns_settings Sortable */
1
/* global kohaTable columns_settings Sortable */
2
2
3
function init() {
3
function init() {
4
    $("#ajax_status").hide();
4
    $("#ajax_status").hide();
Lines 71-78 $(document).ready(function () { Link Here
71
        });
71
        });
72
    }
72
    }
73
73
74
    KohaTable(
74
    $("#stock_rotation_manage_items").kohaTable(
75
        "stock_rotation_manage_items",
76
        {
75
        {
77
            columnDefs: [
76
            columnDefs: [
78
                { orderable: false, searchable: false, targets: ["NoSort"] },
77
                { orderable: false, searchable: false, targets: ["NoSort"] },
Lines 84-91 $(document).ready(function () { Link Here
84
        stock_rotation_items_table_settings
83
        stock_rotation_items_table_settings
85
    );
84
    );
86
85
87
    KohaTable(
86
    $("#stock_rotation").kohaTable(
88
        "stock_rotation",
89
        {
87
        {
90
            columnDefs: [
88
            columnDefs: [
91
                { orderable: false, searchable: false, targets: ["NoSort"] },
89
                { orderable: false, searchable: false, targets: ["NoSort"] },
(-)a/koha-tmpl/intranet-tmpl/prog/js/restrictiontypes.js (-1 / +1 lines)
Lines 26-32 jQuery.validator.addMethod( Link Here
26
);
26
);
27
27
28
$(document).ready(function () {
28
$(document).ready(function () {
29
    KohaTable("restriction_types", {
29
    $("#restriction_types").kohaTable({
30
        columnDefs: [
30
        columnDefs: [
31
            {
31
            {
32
                targets: [-1],
32
                targets: [-1],
(-)a/koha-tmpl/intranet-tmpl/prog/js/viewlog.js (-3 / +1 lines)
Lines 120-127 $(document).ready(function () { Link Here
120
        }
120
        }
121
    });
121
    });
122
122
123
    var logst = KohaTable(
123
    var logst = $("#logst").kohaTable(
124
        "logst",
125
        {
124
        {
126
            autoWidth: false,
125
            autoWidth: false,
127
            order: [[0, "desc"]],
126
            order: [[0, "desc"]],
128
- 

Return to bug 26553