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

(-)a/C4/Biblio.pm (-3 / +2 lines)
Lines 1689-1701 sub GetMarcISBN { Link Here
1689
    } else {    # assume marc21 if not unimarc
1689
    } else {    # assume marc21 if not unimarc
1690
        $scope = '020';
1690
        $scope = '020';
1691
    }
1691
    }
1692
1692
    my @marcisbns;
1693
    my @marcisbns;
1693
    my $marcisbn;
1694
    foreach my $field ( $record->field($scope) ) {
1694
    foreach my $field ( $record->field($scope) ) {
1695
        my $isbn = $field->as_string();
1695
        my $isbn = $field->as_string();
1696
        if ( $isbn ne "" ) {
1696
        if ( $isbn ne "" ) {
1697
            $marcisbn = { marcisbn => $isbn, };
1697
            push @marcisbns, $isbn;
1698
            push @marcisbns, $marcisbn;
1699
        }
1698
        }
1700
    }
1699
    }
1701
1700
(-)a/koha-tmpl/intranet-tmpl/prog/en/modules/catalogue/detail.tt (-1 / +1 lines)
Lines 416-422 function verify_images() { Link Here
416
        <div class="yui-u" style="margin-top: 1em;">
416
        <div class="yui-u" style="margin-top: 1em;">
417
        <ul>
417
        <ul>
418
        [% IF ( MARCISBNS ) %]
418
        [% IF ( MARCISBNS ) %]
419
            <li><strong>ISBN:</strong><ul>[% FOREACH MARCISBN IN MARCISBNS %]<li>[% MARCISBN.marcisbn %]</li>[% END %]</ul></li>
419
            <li><strong>ISBN:</strong><ul>[% FOREACH MARCISBN IN MARCISBNS %]<li>[% MARCISBN %]</li>[% END %]</ul></li>
420
        [% ELSE %]
420
        [% ELSE %]
421
            [% IF ( normalized_isbn ) %]
421
            [% IF ( normalized_isbn ) %]
422
                <li><strong>ISBN:</strong> [% normalized_isbn %]</li>
422
                <li><strong>ISBN:</strong> [% normalized_isbn %]</li>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-detail.tt (-1 / +1 lines)
Lines 197-203 Link Here
197
                        [% END %]
197
                        [% END %]
198
198
199
                        [% IF ( MARCISBNS ) %]
199
                        [% IF ( MARCISBNS ) %]
200
                            <span class="results_summary isbn"><span class="label">ISBN:</span>[% FOREACH MARCISBN IN MARCISBNS %][% MARCISBN.marcisbn %][% IF ( loop.last ) %].[% ELSE %]; [% END %][% END %]</span>
200
                            <span class="results_summary isbn"><span class="label">ISBN:</span>[% FOREACH MARCISBN IN MARCISBNS %][% MARCISBN %][% IF ( loop.last ) %].[% ELSE %]; [% END %][% END %]</span>
201
                        [% ELSE %]
201
                        [% ELSE %]
202
                            [% IF ( normalized_isbn ) %]
202
                            [% IF ( normalized_isbn ) %]
203
                                <span class="results_summary isbn"><span class="label">ISBN: </span>[% normalized_isbn %]</span>
203
                                <span class="results_summary isbn"><span class="label">ISBN: </span>[% normalized_isbn %]</span>
(-)a/koha-tmpl/opac-tmpl/bootstrap/en/modules/opac-sendshelf.tt (-1 / +1 lines)
Lines 59-65 Your list : [% shelfname %] Link Here
59
            [% IF ( BIBLIO_RESULT.ISBN && BIBLIO_RESULT.size > 0 ) %]
59
            [% IF ( BIBLIO_RESULT.ISBN && BIBLIO_RESULT.size > 0 ) %]
60
            <span>
60
            <span>
61
                ISBN: [% FOREACH isbn IN BIBLIO_RESULT.ISBN %]
61
                ISBN: [% FOREACH isbn IN BIBLIO_RESULT.ISBN %]
62
                          [% isbn.marcisbn %]
62
                          [% isbn %]
63
                          [% UNLESS ( loop.last ) %]; [% END %]
63
                          [% UNLESS ( loop.last ) %]; [% END %]
64
                      [% END %]
64
                      [% END %]
65
            </span><br/>
65
            </span><br/>
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-detail.tt (-1 / +1 lines)
Lines 651-657 YAHOO.util.Event.onContentReady("furtherm", function () { Link Here
651
    [% IF ( pages ) %]<span class="results_summary physical"><span class="label">Physical details:</span> [% pages %] [% illus %] [% size %]</span>[% END %]
651
    [% IF ( pages ) %]<span class="results_summary physical"><span class="label">Physical details:</span> [% pages %] [% illus %] [% size %]</span>[% END %]
652
652
653
    [% IF ( MARCISBNS ) %]
653
    [% IF ( MARCISBNS ) %]
654
        <span class="results_summary isbn"><span class="label">ISBN:</span>[% FOREACH MARCISBN IN MARCISBNS %][% MARCISBN.marcisbn %][% IF ( loop.last ) %].[% ELSE %]; [% END %][% END %]</span>
654
        <span class="results_summary isbn"><span class="label">ISBN:</span>[% FOREACH MARCISBN IN MARCISBNS %][% MARCISBN %][% IF ( loop.last ) %].[% ELSE %]; [% END %][% END %]</span>
655
    [% ELSE %]
655
    [% ELSE %]
656
        [% IF ( normalized_isbn ) %]
656
        [% IF ( normalized_isbn ) %]
657
            <span class="results_summary isbn"><span class="label">ISBN: </span>[% normalized_isbn %]</span>
657
            <span class="results_summary isbn"><span class="label">ISBN: </span>[% normalized_isbn %]</span>
(-)a/koha-tmpl/opac-tmpl/prog/en/modules/opac-sendshelf.tt (-1 / +1 lines)
Lines 59-65 Your list : [% shelfname %] Link Here
59
            [% IF ( BIBLIO_RESULT.ISBN && BIBLIO_RESULT.size > 0 ) %]
59
            [% IF ( BIBLIO_RESULT.ISBN && BIBLIO_RESULT.size > 0 ) %]
60
            <span>
60
            <span>
61
                ISBN: [% FOREACH isbn IN BIBLIO_RESULT.ISBN %]
61
                ISBN: [% FOREACH isbn IN BIBLIO_RESULT.ISBN %]
62
                          [% isbn.marcisbn %]
62
                          [% isbn %]
63
                          [% UNLESS ( loop.last ) %]; [% END %]
63
                          [% UNLESS ( loop.last ) %]; [% END %]
64
                      [% END %]
64
                      [% END %]
65
            </span><br/>
65
            </span><br/>
(-)a/t/db_dependent/Biblio.t (-4 / +2 lines)
Lines 19-25 use Modern::Perl; Link Here
19
19
20
use Test::More tests => 3;
20
use Test::More tests => 3;
21
use Test::MockModule;
21
use Test::MockModule;
22
use Data::Dumper;
23
22
24
use MARC::Record;
23
use MARC::Record;
25
24
Lines 166-172 sub run_tests { Link Here
166
    $record_for_isbn->append_fields( $isbn_field );
165
    $record_for_isbn->append_fields( $isbn_field );
167
    $isbns = GetMarcISBN( $record_for_isbn, $marcflavour );
166
    $isbns = GetMarcISBN( $record_for_isbn, $marcflavour );
168
    is( scalar @$isbns, 1, '(GetMarcISBN) The record contains one ISBN');
167
    is( scalar @$isbns, 1, '(GetMarcISBN) The record contains one ISBN');
169
    is( $isbns->[0]->{ marcisbn }, $isbn, '(GetMarcISBN) The record contains our ISBN');
168
    is( $isbns->[0], $isbn, '(GetMarcISBN) The record contains our ISBN');
170
169
171
    # We add 3 more ISBNs
170
    # We add 3 more ISBNs
172
    $record_for_isbn = MARC::Record->new();
171
    $record_for_isbn = MARC::Record->new();
Lines 178-184 sub run_tests { Link Here
178
    $isbns = GetMarcISBN( $record_for_isbn, $marcflavour );
177
    $isbns = GetMarcISBN( $record_for_isbn, $marcflavour );
179
    is( scalar @$isbns, 4, '(GetMarcISBN) The record contains 4 ISBNs');
178
    is( scalar @$isbns, 4, '(GetMarcISBN) The record contains 4 ISBNs');
180
    for my $i (0 .. $#more_isbns) {
179
    for my $i (0 .. $#more_isbns) {
181
        is( $isbns->[$i]->{ marcisbn }, $more_isbns[$i],
180
        is( $isbns->[$i], $more_isbns[$i],
182
            "(GetMarcISBN) Corretly retrieves ISBN #". ($i + 1));
181
            "(GetMarcISBN) Corretly retrieves ISBN #". ($i + 1));
183
    }
182
    }
184
183
185
- 

Return to bug 11912