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

(-)a/koha-tmpl/opac-tmpl/bootstrap/en/includes/opac-detail-sidebar.inc (-5 / +3 lines)
Lines 58-69 Link Here
58
            <div id="export">
58
            <div id="export">
59
                <div class="dropdown">
59
                <div class="dropdown">
60
                    <a id="format" class="btn btn-link btn-lg dropdown-toggle" data-toggle="dropdown" href="#"><i class="fa fa-fw fa-download"></i> Save record <b class="caret"></b></a>
60
                    <a id="format" class="btn btn-link btn-lg dropdown-toggle" data-toggle="dropdown" href="#"><i class="fa fa-fw fa-download"></i> Save record <b class="caret"></b></a>
61
                        <ul class="dropdown-menu pull-left" role="menu" aria-labelledby="format">
61
                        <div class="dropdown-menu dropdown-menu-right" role="menu" aria-labelledby="format">
62
                            [% FOREACH option IN export_options %]
62
                            [% FOREACH option IN export_options %]
63
                                [% IF option == 'dc' %]
63
                                [% IF option == 'dc' %]
64
                                    <li><a role="menuitem" href="#" data-toggle="modal" data-target="#exportModal_">Dublin Core</a></li>
64
                                    <a role="menuitem" href="#" data-toggle="modal" data-target="#exportModal_">Dublin Core</a>
65
                                [% ELSIF option != 'custom' %]
65
                                [% ELSIF option != 'custom' %]
66
                                <li>
67
                                    <a role="menuitem" href="/cgi-bin/koha/opac-export.pl?op=export&amp;bib=[% biblio.biblionumber | html %]&amp;format=[% option | html %]">
66
                                    <a role="menuitem" href="/cgi-bin/koha/opac-export.pl?op=export&amp;bib=[% biblio.biblionumber | html %]&amp;format=[% option | html %]">
68
                                        [% SWITCH option %]
67
                                        [% SWITCH option %]
69
                                            [% CASE 'bibtex' %]BIBTEX
68
                                            [% CASE 'bibtex' %]BIBTEX
Lines 77-90 Link Here
77
                                            [% CASE 'isbd' %]ISBD
76
                                            [% CASE 'isbd' %]ISBD
78
                                        [% END %]
77
                                        [% END %]
79
                                    </a>
78
                                    </a>
80
                                </li>
81
                                [% ELSE %]
79
                                [% ELSE %]
82
                                    [% FOREACH filesOption IN filesOptions %]
80
                                    [% FOREACH filesOption IN filesOptions %]
83
                                        <li><a role="menuitem" href="/cgi-bin/koha/opac-export.pl?format=[% filesOption.format | html %]&amp;op=exportxsl&amp;file=[% filesOption.value | html %]&amp;bib=[% biblionumber | html %]">XSL - [% filesOption.filename | html %]</a></li>
81
                                        <li><a role="menuitem" href="/cgi-bin/koha/opac-export.pl?format=[% filesOption.format | html %]&amp;op=exportxsl&amp;file=[% filesOption.value | html %]&amp;bib=[% biblionumber | html %]">XSL - [% filesOption.filename | html %]</a></li>
84
                                    [% END %]
82
                                    [% END %]
85
                                [% END %]
83
                                [% END %]
86
                            [% END %]
84
                            [% END %]
87
                        </ul>
85
                        </div>
88
                </div>
86
                </div>
89
            </div>
87
            </div>
90
        </li>
88
        </li>
(-)a/t/db_dependent/XSLT.t (-4 / +3 lines)
Lines 18-24 Link Here
18
use Modern::Perl;
18
use Modern::Perl;
19
19
20
use MARC::Record;
20
use MARC::Record;
21
use Test::More tests => 4;
21
use Test::More tests =>  7;
22
use Test::Warn;
22
use Test::Warn;
23
use t::lib::TestBuilder;
23
use t::lib::TestBuilder;
24
use t::lib::Mocks;
24
use t::lib::Mocks;
Lines 47-54 subtest 'CustomXSLTExportList: Caching' => sub { Link Here
47
    push @$list, { nonsense => 1 };
47
    push @$list, { nonsense => 1 };
48
    $cache->set_in_cache( 'CustomXSLTExportListOPAC', $list );
48
    $cache->set_in_cache( 'CustomXSLTExportListOPAC', $list );
49
    my $n = @$list;
49
    my $n = @$list;
50
    $list = C4::XSLT::CustomXSLTExportList(1);
51
    is( @$list, $n, 'This list comes from the cache and that is fine' );
50
    is( @$list, $n, 'This list comes from the cache and that is fine' );
51
    $list = C4::XSLT::CustomXSLTExportList(1);
52
    $cache->clear_from_cache('CustomXSLTExportListOPAC');
52
    $cache->clear_from_cache('CustomXSLTExportListOPAC');
53
};
53
};
54
54
Lines 166-173 subtest 'CustomXSLTExportList: Caching' => sub { Link Here
166
    push @$list, { nonsense => 1 };
166
    push @$list, { nonsense => 1 };
167
    $cache->set_in_cache('CustomXSLTExportListOPAC', $list );
167
    $cache->set_in_cache('CustomXSLTExportListOPAC', $list );
168
    my $n = @$list;
168
    my $n = @$list;
169
    $list = C4::XSLT::CustomXSLTExportList(1);
170
    is( @$list, $n, 'This list comes from the cache and that is fine' );
169
    is( @$list, $n, 'This list comes from the cache and that is fine' );
170
    $list = C4::XSLT::CustomXSLTExportList(1);
171
    $cache->clear_from_cache('CustomXSLTExportListOPAC');
171
    $cache->clear_from_cache('CustomXSLTExportListOPAC');
172
};
172
};
173
subtest 'CustomXSLTExportList: Check export options' => sub {
173
subtest 'CustomXSLTExportList: Check export options' => sub {
174
- 

Return to bug 17385