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

(-)a/C4/Biblio.pm (+6 lines)
Lines 1834-1842 sub GetMarcAuthors { Link Here
1834
        }
1834
        }
1835
1835
1836
        # other subfields
1836
        # other subfields
1837
        my $unimarc3;
1837
        for my $authors_subfield (@subfields) {
1838
        for my $authors_subfield (@subfields) {
1838
            next if ( $authors_subfield->[0] eq '9' );
1839
            next if ( $authors_subfield->[0] eq '9' );
1839
1840
1841
            # unimarc3 contains the $3 of the author for UNIMARC.
1842
            # For french academic libraries, it's the "ppn", and it's required for idref webservice
1843
            $unimarc3 = $authors_subfield->[1] if $marcflavour eq 'UNIMARC' and $authors_subfield->[0] =~ /3/;
1844
1840
            # don't load unimarc subfields 3, 5
1845
            # don't load unimarc subfields 3, 5
1841
            next if ( $marcflavour eq 'UNIMARC' and ( $authors_subfield->[0] =~ /3|5/ ) );
1846
            next if ( $marcflavour eq 'UNIMARC' and ( $authors_subfield->[0] =~ /3|5/ ) );
1842
1847
Lines 1872-1877 sub GetMarcAuthors { Link Here
1872
        push @marcauthors, {
1877
        push @marcauthors, {
1873
            MARCAUTHOR_SUBFIELDS_LOOP => \@subfields_loop,
1878
            MARCAUTHOR_SUBFIELDS_LOOP => \@subfields_loop,
1874
            authoritylink => $subfield9,
1879
            authoritylink => $subfield9,
1880
            unimarc3 => $unimarc3
1875
        };
1881
        };
1876
    }
1882
    }
1877
    return \@marcauthors;
1883
    return \@marcauthors;
(-)a/etc/zebradb/marc_defs/unimarc/biblios/record.abs (+7 lines)
Lines 101-114 melm 701 Author,Personal-name,Author:p,Personal-name:p,Personal-name:p Link Here
101
melm 702$9      Koha-Auth-Number,Koha-Auth-Number:n
101
melm 702$9      Koha-Auth-Number,Koha-Auth-Number:n
102
melm 702        Author,Personal-name,Author:p,Personal-name:p,Personal-name:p
102
melm 702        Author,Personal-name,Author:p,Personal-name:p,Personal-name:p
103
103
104
melm 700$3      Identified-standard
105
melm 701$3      Identified-standard
106
melm 702$3      Identified-standard
107
104
# collective Author
108
# collective Author
105
melm 710$9        Koha-Auth-Number,Koha-Auth-Number:n
109
melm 710$9        Koha-Auth-Number,Koha-Auth-Number:n
106
melm 710    Author,Author-name-corporate,Author-name-conference,Corporate-name,Conference-name,Author:p,Author-name-corporate:p,Author-name-conference:p,Corporate-name:p,Conference-name:p
110
melm 710    Author,Author-name-corporate,Author-name-conference,Corporate-name,Conference-name,Author:p,Author-name-corporate:p,Author-name-conference:p,Corporate-name:p,Conference-name:p
111
melm 710$3      Identified-standard
107
melm 711$9        Koha-Auth-Number,Koha-Auth-Number:n
112
melm 711$9        Koha-Auth-Number,Koha-Auth-Number:n
108
melm 711    Author,Author-name-corporate,Author-name-conference,Corporate-name,Conference-name,Author:p,Author-name-corporate:p,Author-name-conference:p,Corporate-name:p,Conference-name:p
113
melm 711    Author,Author-name-corporate,Author-name-conference,Corporate-name,Conference-name,Author:p,Author-name-corporate:p,Author-name-conference:p,Corporate-name:p,Conference-name:p
114
melm 711$3      Identified-standard
109
115
110
melm 712$9        Koha-Auth-Number,Koha-Auth-Number:n
116
melm 712$9        Koha-Auth-Number,Koha-Auth-Number:n
111
melm 712    Author,Author-name-corporate,Author-name-conference,Corporate-name,Conference-name,Author:p,Author-name-corporate:p,Author-name-conference:p,Corporate-name:p,Conference-name:p
117
melm 712    Author,Author-name-corporate,Author-name-conference,Corporate-name,Conference-name,Author:p,Author-name-corporate:p,Author-name-conference:p,Corporate-name:p,Conference-name:p
118
melm 712$3      Identified-standard
112
119
113
############## TITLE ##################
120
############## TITLE ##################
114
# main Title
121
# main Title
(-)a/installer/data/mysql/updatedatabase.pl (+16 lines)
Lines 6020-6025 if (C4::Context->preference("Version") < TransformToNum($DBversion)) { Link Here
6020
   SetVersion ($DBversion);
6020
   SetVersion ($DBversion);
6021
}
6021
}
6022
6022
6023
6024
6025
6026
$DBversion = "3.09.00.XXX";
6027
if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) {
6028
    $dbh->do(qq{
6029
        INSERT INTO systempreferences (variable,value,explanation,options,type)
6030
        VALUES('IDREF','0','Disable/enable the IDREF webservice from the OPAC detail page.',NULL,'YesNo')
6031
    });
6032
    print "Upgrade to $DBversion done (Add system preference IDREF))\n";
6033
    SetVersion($DBversion);
6034
}
6035
6036
6037
6038
6023
=head1 FUNCTIONS
6039
=head1 FUNCTIONS
6024
6040
6025
=head2 TableExists($table)
6041
=head2 TableExists($table)
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/web_services.pref (+7 lines)
Lines 44-46 Web services: Link Here
44
            - pref: SvcMaxReportRows
44
            - pref: SvcMaxReportRows
45
              class: integer
45
              class: integer
46
            - rows of a report requested via the reports web service.
46
            - rows of a report requested via the reports web service.
47
    IDREF:
48
        -
49
            - pref: IDREF
50
              choices:
51
                yes: Enable
52
                no: Disable
53
            - the IDREF webservice from the opac detail page
(-)a/koha-tmpl/opac-tmpl/prog/en/css/datatables.css (-21 / +21 lines)
Lines 3-25 input.search_init { Link Here
3
}
3
}
4
.sorting_asc {
4
.sorting_asc {
5
    padding-right: 19px;
5
    padding-right: 19px;
6
    background: url("../../img/asc.gif") no-repeat scroll right center #EEEEEE;
6
    background: url("../../images/asc.gif") no-repeat scroll right center #EEEEEE;
7
}
7
}
8
.sorting_desc {
8
.sorting_desc {
9
    padding-right: 19px;
9
    padding-right: 19px;
10
    background: url("../../img/desc.gif") no-repeat scroll right center #EEEEEE;
10
    background: url("../../images/desc.gif") no-repeat scroll right center #EEEEEE;
11
}
11
}
12
.sorting {
12
.sorting {
13
    padding-right: 19px;
13
    padding-right: 19px;
14
    background: url("../../img/ascdesc.gif") no-repeat scroll right center #EEEEEE;
14
    background: url("../../images/ascdesc.gif") no-repeat scroll right center #EEEEEE;
15
}
15
}
16
.sorting_asc_disabled {
16
.sorting_asc_disabled {
17
    padding-right: 19px;
17
    padding-right: 19px;
18
    background: url("../../img/datatables/sort_asc_disabled.png") no-repeat scroll right center #EEEEEE;
18
    background: url("../../images/datatables/sort_asc_disabled.png") no-repeat scroll right center #EEEEEE;
19
}
19
}
20
.sorting_desc_disabled {
20
.sorting_desc_disabled {
21
    padding-right: 19px;
21
    padding-right: 19px;
22
    background: url("../../img/datatables/sort_desc_disabled.png") no-repeat scroll right center #EEEEEE;
22
    background: url("../../images/datatables/sort_desc_disabled.png") no-repeat scroll right center #EEEEEE;
23
}
23
}
24
.sorting_disabled {
24
.sorting_disabled {
25
    padding-right: 19px;
25
    padding-right: 19px;
Lines 83-107 div.dataTables_paginate { Link Here
83
    color : #0000CC;
83
    color : #0000CC;
84
}
84
}
85
.paging_full_numbers span.paginate_button.first {
85
.paging_full_numbers span.paginate_button.first {
86
    background-image : url('../../img/first.png');
86
    background-image : url('../../images/first.png');
87
    background-repeat: no-repeat;
87
    background-repeat: no-repeat;
88
    background-position : 2px center;
88
    background-position : 2px center;
89
    padding-left : 2em;
89
    padding-left : 2em;
90
}
90
}
91
.paging_full_numbers span.paginate_button.previous {
91
.paging_full_numbers span.paginate_button.previous {
92
    background-image : url('../../img/prev.png');
92
    background-image : url('../../images/prev.png');
93
    background-repeat: no-repeat;
93
    background-repeat: no-repeat;
94
    background-position : 2px center;
94
    background-position : 2px center;
95
    padding-left : 2em;
95
    padding-left : 2em;
96
}
96
}
97
.paging_full_numbers span.paginate_button.next {
97
.paging_full_numbers span.paginate_button.next {
98
    background-image : url('../../img/next.png');
98
    background-image : url('../../images/next.png');
99
    background-repeat: no-repeat;
99
    background-repeat: no-repeat;
100
    background-position : right center;
100
    background-position : right center;
101
    padding-right : 2em;
101
    padding-right : 2em;
102
}
102
}
103
.paging_full_numbers span.paginate_button.last {
103
.paging_full_numbers span.paginate_button.last {
104
    background-image : url('../../img/last.png');
104
    background-image : url('../../images/last.png');
105
    background-repeat: no-repeat;
105
    background-repeat: no-repeat;
106
    background-position : right center;
106
    background-position : right center;
107
    border-right : 1px solid #686868;
107
    border-right : 1px solid #686868;
Lines 147-177 div.dataTables_paginate.paging_four_button { Link Here
147
    width: 16px;
147
    width: 16px;
148
}
148
}
149
.paginate_disabled_first {
149
.paginate_disabled_first {
150
    background-image: url("../../img/first-disabled.png");
150
    background-image: url("../../images/first-disabled.png");
151
}
151
}
152
.paginate_enabled_first {
152
.paginate_enabled_first {
153
    background-image: url("../../img/first.png");
153
    background-image: url("../../images/first.png");
154
    cursor: pointer;
154
    cursor: pointer;
155
}
155
}
156
.paginate_disabled_previous {
156
.paginate_disabled_previous {
157
    background-image: url("../../img/prev-disabled.png");
157
    background-image: url("../../images/prev-disabled.png");
158
}
158
}
159
.paginate_enabled_previous {
159
.paginate_enabled_previous {
160
    background-image: url("../../img/prev.png");
160
    background-image: url("../../images/prev.png");
161
    cursor: pointer;
161
    cursor: pointer;
162
}
162
}
163
.paginate_disabled_next {
163
.paginate_disabled_next {
164
    background-image: url("../../img/next-disabled.png");
164
    background-image: url("../../images/next-disabled.png");
165
}
165
}
166
.paginate_enabled_next {
166
.paginate_enabled_next {
167
    background-image: url("../../img/next.png");
167
    background-image: url("../../images/next.png");
168
    cursor: pointer;
168
    cursor: pointer;
169
}
169
}
170
.paginate_disabled_last {
170
.paginate_disabled_last {
171
    background-image: url("../../img/last-disabled.png");
171
    background-image: url("../../images/last-disabled.png");
172
}
172
}
173
.paginate_enabled_last {
173
.paginate_enabled_last {
174
    background-image: url("../../img/last.png");
174
    background-image: url("../../images/last.png");
175
    cursor: pointer;
175
    cursor: pointer;
176
}
176
}
177
177
Lines 248-263 table.display thead th { Link Here
248
    width: 19px;
248
    width: 19px;
249
}
249
}
250
.paginate_disabled_previous {
250
.paginate_disabled_previous {
251
    background-image: url("../../img/datatables/back_disabled.jpg");
251
    background-image: url("../../images/datatables/back_disabled.jpg");
252
}
252
}
253
.paginate_enabled_previous {
253
.paginate_enabled_previous {
254
    background-image: url("../../img/datatables/back_enabled.jpg");
254
    background-image: url("../../images/datatables/back_enabled.jpg");
255
}
255
}
256
.paginate_disabled_next {
256
.paginate_disabled_next {
257
    background-image: url("../../img/datatables/forward_disabled.jpg");
257
    background-image: url("../../images/datatables/forward_disabled.jpg");
258
}
258
}
259
.paginate_enabled_next {
259
.paginate_enabled_next {
260
    background-image: url("../../img/datatables/forward_enabled.jpg");
260
    background-image: url("../../images/datatables/forward_enabled.jpg");
261
}
261
}
262
.spacer {
262
.spacer {
263
    clear: both;
263
    clear: both;
(-)a/koha-tmpl/opac-tmpl/prog/en/css/opac.css (+41 lines)
Lines 2820-2822 body#opac-main #opacmainuserblockmobile { Link Here
2820
.tagweight9 {
2820
.tagweight9 {
2821
    font-size: 30px;
2821
    font-size: 30px;
2822
}
2822
}
2823
2824
div.pager {
2825
    background-color : #E8E8E8;
2826
    border : 1px solid #BCBCBC;
2827
    -moz-border-radius : 5px;
2828
    display : inline-block;
2829
    font-size : 85%;
2830
    padding : .3em .5em .3em .5em;
2831
    margin : .4em 0;
2832
}
2833
div.pager img {
2834
    vertical-align : middle;
2835
}
2836
div.pager img.last {
2837
    padding-right: 5px;
2838
}
2839
div.pager input.pagedisplay {
2840
    border : 0;
2841
    background-color : transparent;
2842
    font-weight: bold;
2843
    text-align : center;
2844
}
2845
a.localimage img {
2846
    border : 1px solid #0000CC;
2847
    margin : 0 .5em;
2848
    padding : .3em;
2849
}
2850
div.pager p {
2851
    margin: 0;
2852
}
2853
2854
2855
/* IDREF */
2856
#idref h2.role {
2857
    background-color: #DDDEEE;
2858
    cursor: pointer;
2859
}
2860
2861
#idref table {
2862
    margin: 0;
2863
}
(-)a/koha-tmpl/opac-tmpl/prog/en/includes/greybox.inc (+7 lines)
Line 0 Link Here
1
<script type="text/javascript">
2
    var GB_ROOT_DIR = "[% themelang %]/lib/greybox/";
3
</script>
4
<script type="text/javascript" src="[% themelang %]/lib/greybox/AJS.js"></script>
5
<script type="text/javascript" src="[% themelang %]/lib/greybox/AJS_fx.js"></script>
6
<script type="text/javascript" src="[% themelang %]/lib/greybox/gb_scripts.js"></script>
7
<link href="[% themelang %]/lib/greybox/gb_styles.css" rel="stylesheet" type="text/css" />
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt (-1 / +9 lines)
Lines 11-16 Link Here
11
[% END %]
11
[% END %]
12
[% IF ( OpacStarRatings != 'disable' ) %]<script type="text/javascript" src="/opac-tmpl/prog/en/lib/jquery/plugins/jquery.rating.js"></script>
12
[% IF ( OpacStarRatings != 'disable' ) %]<script type="text/javascript" src="/opac-tmpl/prog/en/lib/jquery/plugins/jquery.rating.js"></script>
13
<link rel="stylesheet" type="text/css" href="/opac-tmpl/prog/en/css/jquery.rating.css" />[% END %]
13
<link rel="stylesheet" type="text/css" href="/opac-tmpl/prog/en/css/jquery.rating.css" />[% END %]
14
[% INCLUDE greybox.inc %]
14
15
15
[% IF ( OpacHighlightedWords ) %]<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.highlight-3.js"></script>[% END %]
16
[% IF ( OpacHighlightedWords ) %]<script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.highlight-3.js"></script>[% END %]
16
<script type="text/JavaScript" language="JavaScript">
17
<script type="text/JavaScript" language="JavaScript">
Lines 345-351 YAHOO.util.Event.onContentReady("furtherm", function () { Link Here
345
        [% XSLTBloc %]
346
        [% XSLTBloc %]
346
    [% ELSE %]
347
    [% ELSE %]
347
    <h1 class="title">[% title |html %][% IF ( subtitle ) %] <span class="subtitle">[% FOREACH subtitl IN subtitle %][% subtitl.subfield |html %] [% END %]</span>[% END %]</h1>
348
    <h1 class="title">[% title |html %][% IF ( subtitle ) %] <span class="subtitle">[% FOREACH subtitl IN subtitle %][% subtitl.subfield |html %] [% END %]</span>[% END %]</h1>
348
    [% IF ( author ) %]<h5 class="author">by <a href="/cgi-bin/koha/opac-search.pl?q=au:[% author |url %]">[% author |html %]</a></h5>[% END %] 
349
    [% IF ( author ) %]
350
      <h5 class="author">
351
        by <a href="/cgi-bin/koha/opac-search.pl?q=au:[% author |url %]">[% author |html %]</a>
352
      </h5>
353
    [% END %]
349
354
350
    <span class="results_summary">[% UNLESS ( item_level_itypes ) %]
355
    <span class="results_summary">[% UNLESS ( item_level_itypes ) %]
351
        [
356
        [
Lines 369-374 YAHOO.util.Event.onContentReady("furtherm", function () { Link Here
369
            [% IF (MARCAUTHOR.authoritylink) %]
374
            [% IF (MARCAUTHOR.authoritylink) %]
370
                <a class='authlink' href="/cgi-bin/koha/opac-authoritiesdetail.pl?authid=[% MARCAUTHOR.authoritylink %]"><img style="vertical-align:middle" height="15" width="15" src="/opac-tmpl/prog/images/filefind.png"></a>
375
                <a class='authlink' href="/cgi-bin/koha/opac-authoritiesdetail.pl?authid=[% MARCAUTHOR.authoritylink %]"><img style="vertical-align:middle" height="15" width="15" src="/opac-tmpl/prog/images/filefind.png"></a>
371
            [% END %]
376
            [% END %]
377
            [% IF ( IDREF and MARCAUTHOR.unimarc3) %]
378
                <a href="/cgi-bin/koha/opac-idref.pl?unimarc3=[% MARCAUTHOR.unimarc3 %]" title="IDREF" rel="gb_page_center[600,500]">IDREF</a>
379
            [% END %]
372
            [% UNLESS ( loop.last ) %]|[% END %]
380
            [% UNLESS ( loop.last ) %]|[% END %]
373
        [% END %]
381
        [% END %]
374
    </span>
382
    </span>
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-idref.tt (+66 lines)
Line 0 Link Here
1
[% INCLUDE 'doc-head-open.inc' %]
2
[% IF ( LibraryNameTitle ) %][% LibraryNameTitle %][% ELSE %]Koha online[% END %] catalog &rsaquo; Your search IDREF for ppn [% unimarc3 %]
3
[% INCLUDE 'doc-head-close.inc' %]
4
  <link rel="stylesheet" href="[% themelang %]/css/datatables.css" />
5
  <script type="text/javascript" src="[% themelang %]/lib/jquery/plugins/jquery.dataTables.min.js"></script>
6
  [% INCLUDE 'datatables-strings.inc' %]
7
  <script type="text/javascript" src="[% themelang %]/js/datatables.js"></script>
8
  <script type="text/javascript">
9
    $(document).ready(function (){
10
        $("table").dataTable($.extend(true, {}, dataTablesDefaults, {
11
            "oLanguage": {
12
                "sSearch": _("Search all columns:")
13
            },
14
            'bFilter': false,
15
            'sPaginationType': 'four_button',
16
            'aoColumnDefs': [
17
                { 'aTargets': [-1, -2], 'bSortable': false }
18
            ],
19
            'aLengthMenu': [[10, 25, 50, 100, 250, 500, 1000, -1], [10, 25, 50, 100, 250, 500, 1000, _("All")]],
20
        }));
21
22
        $(".role").click(function(){
23
            var docs_node = $(this).parent().find("div.docs");
24
            if ( $(docs_node).is(":visible") ) {
25
                $(".docs").hide();
26
            } else {
27
                $(".docs").hide();
28
                docs_node.show();
29
            }
30
        });
31
        $(".docs").hide();
32
    });
33
  </script>
34
</head>
35
<body>
36
<div id="idref">
37
  [% IF error %]
38
    This ppn is not found on the idref service.
39
  [% ELSE %]
40
    [% FOREACH role IN content %]
41
      <div>
42
        <h2 class="role" title="Click to expand this role">[% role.role_name %] ([% role.count %])</h2>
43
          <div class="docs">
44
            <table>
45
              <thead>
46
                <th>Citation</th>
47
                <th>Koha</th>
48
                <th>Sudoc</th>
49
              </thead>
50
              <tbody>
51
                [% FOREACH doc IN role.docs %]
52
                  <tr>
53
                    <td>[% doc.citation %]</td>
54
                    <td><a href="/cgi-bin/koha/opac-search.pl?q=kw,phr=[% doc.ppn %]" target="_blank">Koha</a></td>
55
                    <td><a href="http://www.sudoc.fr/[% doc.ppn %]" target="_blank">Sudoc</a></td>
56
                  </tr>
57
                [% END %]
58
              </tbody>
59
            </table>
60
          </div>
61
      </div>
62
    [% END %]
63
  [% END %]
64
</div>
65
[% INCLUDE 'opac-bottom.inc' %]
66
(-)a/opac/opac-detail.pl (+13 lines)
Lines 950-955 if (my $search_for_title = C4::Context->preference('OPACSearchForTitleIn')){ Link Here
950
    $template->param('OPACSearchForTitleIn' => $search_for_title);
950
    $template->param('OPACSearchForTitleIn' => $search_for_title);
951
}
951
}
952
952
953
#IDREF
954
if ( C4::Context->preference("IDREF") ) {
955
    # If the record comes from the SUDOC
956
    if ( $record->field('009') ) {
957
        my $unimarc3 = $record->field("009")->data;
958
        if ( $unimarc3 =~ /^\d+$/ ) {
959
            $template->param(
960
                IDREF => 1,
961
            );
962
        }
963
    }
964
}
965
953
# We try to select the best default tab to show, according to what
966
# We try to select the best default tab to show, according to what
954
# the user wants, and what's available for display
967
# the user wants, and what's available for display
955
my $opac_serial_default = C4::Context->preference('opacSerialDefaultTab');
968
my $opac_serial_default = C4::Context->preference('opacSerialDefaultTab');
(-)a/opac/opac-idref.pl (-1 / +91 lines)
Line 0 Link Here
0
- 
1
#!/usr/bin/perl
2
3
use Modern::Perl;
4
5
use CGI;
6
use LWP::UserAgent;
7
use HTTP::Request::Common;
8
use JSON;
9
use Encode;
10
11
use C4::Auth;
12
use C4::Context;
13
use C4::Search;
14
use C4::Output;
15
16
my $cgi = new CGI;
17
my ( $template, $borrowernumber, $cookie ) = get_template_and_user(
18
    {
19
        template_name   => "opac-idref.tt",
20
        query           => $cgi,
21
        type            => "opac",
22
        authnotrequired => ( C4::Context->preference("OpacPublic") ? 1 : 0 ),
23
        flagsrequired   => { borrow => 1 },
24
    }
25
);
26
27
my $ua = LWP::UserAgent->new;
28
29
my $base = 'http://www.idref.fr/services/biblio/';
30
my $unimarc3 = $cgi->param('unimarc3');
31
32
my $request = HTTP::Request->new(
33
    'GET',
34
    $base . $unimarc3 . ".json",
35
);
36
$request->protocol('HTTP/1.1');
37
my $response = $ua->request($request);
38
if ( not $response->is_success) {
39
    $template->param(error => $base.$unimarc3.'.json');
40
    output_html_with_http_headers $cgi, $cookie, $template->output;
41
    exit;
42
}
43
44
my $content = Encode::decode("utf8", $response->content);
45
my $json = from_json( $content );
46
my $r;
47
my $role_name;
48
my @unimarc3;
49
my @results = ref $json->{sudoc}{result} eq "ARRAY"
50
            ? @{ $json->{sudoc}{result} }
51
            : ($json->{sudoc}{result});
52
53
for my $role_node ( @results ) {
54
    while ( my ( $k, $v ) = each %$role_node ) {
55
        next unless $k eq "role";
56
        my $role_name;
57
        my $count = 0;
58
        my $role_data = {};
59
        my @nodes = ref $v eq "ARRAY"
60
                    ? @$v
61
                    : ($v);
62
        for my $node ( @nodes ) {
63
            while ( ( $k, $v ) = each %$node ) {
64
                given ( $k ) {
65
                    when ( "roleName" ) {
66
                        $role_name = $v;
67
                        $role_data->{role_name} = $role_name;
68
                    }
69
                    when ( "count" ) {
70
                        $role_data->{count} = $v;
71
                    }
72
                    when ( "doc" ) {
73
                        push @{ $role_data->{docs} }, $v;
74
                    }
75
                    default {
76
                        # unimarcCode and marc21Code
77
                    }
78
                }
79
            }
80
        }
81
        push @$r, $role_data;
82
    }
83
}
84
85
$template->param(
86
    content => $r,
87
    unimarc3 => $unimarc3,
88
);
89
90
output_html_with_http_headers $cgi, $cookie, $template->output;
91

Return to bug 8992