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

(-)a/C4/Koha.pm (+2 lines)
Lines 669-674 sub GetNormalizedOCLCNumber { Link Here
669
    my ($marcrecord,$marcflavour) = @_;
669
    my ($marcrecord,$marcflavour) = @_;
670
    return unless $marcrecord;
670
    return unless $marcrecord;
671
671
672
    $marcflavour ||= C4::Context->preference('marcflavour');
673
672
    if ($marcflavour ne 'UNIMARC' ) {
674
    if ($marcflavour ne 'UNIMARC' ) {
673
        my @fields = $marcrecord->field('035');
675
        my @fields = $marcrecord->field('035');
674
        foreach my $field (@fields) {
676
        foreach my $field (@fields) {
(-)a/Koha/Biblio.pm (-2 / +15 lines)
Lines 23-29 use List::MoreUtils qw( any ); Link Here
23
use URI;
23
use URI;
24
use URI::Escape qw( uri_escape_utf8 );
24
use URI::Escape qw( uri_escape_utf8 );
25
25
26
use C4::Koha qw( GetNormalizedISBN GetNormalizedUPC );
26
use C4::Koha qw( GetNormalizedISBN GetNormalizedUPC GetNormalizedOCLCNumber );
27
27
28
use Koha::Database;
28
use Koha::Database;
29
use Koha::DateUtils qw( dt_from_string );
29
use Koha::DateUtils qw( dt_from_string );
Lines 1258-1263 sub normalized_upc { Link Here
1258
    return C4::Koha::GetNormalizedUPC( $marc_record );
1258
    return C4::Koha::GetNormalizedUPC( $marc_record );
1259
}
1259
}
1260
1260
1261
=head3 normalized_oclc
1262
1263
    my $normalized_oclc = $biblio->normalized_oclc
1264
1265
Normalizes and returns the OCLC number found in the MARC record.
1266
1267
=cut
1268
1269
sub normalized_oclc {
1270
    my ( $self ) = @_;
1271
    my $marc_record = $self->metadata->record;
1272
    return C4::Koha::GetNormalizedOCLCNumber( $marc_record );
1273
}
1274
1261
=head3 to_api
1275
=head3 to_api
1262
1276
1263
    my $json = $biblio->to_api;
1277
    my $json = $biblio->to_api;
1264
- 

Return to bug 33958