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

(-)a/Koha/Biblio.pm (-6 / +21 lines)
Lines 1806-1815 sub generate_marc_host_field { Link Here
1806
        }
1806
        }
1807
1807
1808
        # Publication
1808
        # Publication
1809
        if ( $host_field = $marc_host->field('260') ) {
1809
        my @publication_fields = $marc_host->field('264');
1810
            my $s = $host_field->as_string('abc');
1810
        # Fallback to 260 if there are no 264
1811
            if ($s) {
1811
        @publication_fields = $marc_host->field('260') unless (@publication_fields);
1812
                $sfd{d} = $s;
1812
        my $index = 0;
1813
        for my $host_field (@publication_fields) {
1814
1815
            # Use first entry unless we find a prefered indicator1 = 3
1816
            if ( $index == 0 ) {
1817
                my $s = $host_field->as_string('abc');
1818
                if ($s) {
1819
                    $sfd{d} = $s;
1820
                }
1821
                $index++;
1822
            }
1823
            if ( $host_field->indicator(1) == 3 ) {
1824
                my $s = $host_field->as_string('abc');
1825
                if ($s) {
1826
                    $sfd{d} = $s;
1827
                }
1828
                last;
1813
            }
1829
            }
1814
        }
1830
        }
1815
1831
Lines 1823-1829 sub generate_marc_host_field { Link Here
1823
1839
1824
        # Title
1840
        # Title
1825
        if ( $host_field = $marc_host->field('245') ) {
1841
        if ( $host_field = $marc_host->field('245') ) {
1826
            my $s = $host_field->as_string('ab');
1842
            my $s = $host_field->as_string('abnp');
1827
            if ($s) {
1843
            if ($s) {
1828
                $sfd{t} = $s;
1844
                $sfd{t} = $s;
1829
            }
1845
            }
1830
- 

Return to bug 37364