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

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/columns_settings.inc (-6 / +13 lines)
Lines 1-6 Link Here
1
[% USE ColumnsSettings %]
1
[% USE ColumnsSettings %]
2
2
3
<script type="text/javascript">
3
<script>
4
function KohaTable(id_selector, dt_parameters, columns_settings, add_filters) {
4
function KohaTable(id_selector, dt_parameters, columns_settings, add_filters) {
5
    var counter = 0;
5
    var counter = 0;
6
    var hidden_ids = [];
6
    var hidden_ids = [];
Lines 20-60 function KohaTable(id_selector, dt_parameters, columns_settings, add_filters) { Link Here
20
        }
20
        }
21
        counter++;
21
        counter++;
22
    });
22
    });
23
24
    var exportColumns = ":visible";
25
    if( dt_parameters.hasOwnProperty("exportColumns") ){
26
        // A custom buttons configuration has been passed from the page
27
        exportColumns = dt_parameters["exportColumns"];
28
    }
29
23
    dt_parameters[ "buttons" ] = [
30
    dt_parameters[ "buttons" ] = [
24
        {
31
        {
25
            extend: 'colvis',
32
            extend: 'colvis',
26
            columns: included_ids,
33
            columns: included_ids,
27
            text: _("Column visibility"),
34
            text: _("Column visibility"),
28
            exportOptions: {
35
            exportOptions: {
29
                columns: ':visible'
36
                columns: exportColumns
30
            },
37
            },
31
        },
38
        },
32
        {
39
        {
33
            extend: 'excelHtml5',
40
            extend: 'excelHtml5',
34
            text: _("Excel"),
41
            text: _("Excel"),
35
            exportOptions: {
42
            exportOptions: {
36
                columns: ':visible'
43
                columns: exportColumns
37
            },
44
            },
38
        },
45
        },
39
        {
46
        {
40
            extend: 'csvHtml5',
47
            extend: 'csvHtml5',
41
            text: _("CSV"),
48
            text: _("CSV"),
42
            exportOptions: {
49
            exportOptions: {
43
                columns: ':visible'
50
                columns: exportColumns
44
            },
51
            },
45
        },
52
        },
46
        {
53
        {
47
            extend: 'copyHtml5',
54
            extend: 'copyHtml5',
48
            text: _("Copy"),
55
            text: _("Copy"),
49
            exportOptions: {
56
            exportOptions: {
50
                columns: ':visible'
57
                columns: exportColumns
51
            },
58
            },
52
        },
59
        },
53
        {
60
        {
54
            extend: 'print',
61
            extend: 'print',
55
            text: _("Print"),
62
            text: _("Print"),
56
            exportOptions: {
63
            exportOptions: {
57
                columns: ':visible'
64
                columns: exportColumns
58
            },
65
            },
59
        },
66
        },
60
    ];
67
    ];
(-)a/koha-tmpl/intranet-tmpl/prog/js/letter.js (-2 / +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 MSG_EMPTY_TITLE_AND_CONTENT MSG_EMPTY_TEMPLATES code MSG_CODE_EXISTS MSG_CODE_EXISTS_FOR_LIBRARY MSG_DT_LOADING_RECORDS interface theme KohaTable columns_settings */
2
/* global _ module add_form copy_form no_op_set MSG_EMPTY_TITLE_AND_CONTENT MSG_EMPTY_TEMPLATES code MSG_CODE_EXISTS MSG_CODE_EXISTS_FOR_LIBRARY MSG_DT_LOADING_RECORDS MSG_NO_NOTICE_FOUND interface theme KohaTable columns_settings */
3
3
4
var modal_loading = "<div id=\"loading\"><img src=\"" + interface + "/" + theme + "/img/spinner-small.gif\" alt=\"\" /> "+ MSG_DT_LOADING_RECORDS +"</div>";
4
var modal_loading = "<div id=\"loading\"><img src=\"" + interface + "/" + theme + "/img/spinner-small.gif\" alt=\"\" /> "+ MSG_DT_LOADING_RECORDS +"</div>";
5
5
Lines 46-51 $(document).ready(function() { Link Here
46
        "oLanguage": {
46
        "oLanguage": {
47
            "sZeroRecords": MSG_NO_NOTICE_FOUND
47
            "sZeroRecords": MSG_NO_NOTICE_FOUND
48
        },
48
        },
49
        "exportColumns": [0,1,2,3],
49
    }, columns_settings);
50
    }, columns_settings);
50
51
51
    if( no_op_set ){
52
    if( no_op_set ){
52
- 

Return to bug 21216