- my $biblios = GetImportBibliosRange($import_batch_id, $offset, $results_per_page);
- my @list = ();
- foreach my $biblio (@$biblios) {
- my $citation = $biblio->{'title'};
- $citation .= " $biblio->{'author'}" if $biblio->{'author'};
- $citation .= " (" if $biblio->{'issn'} or $biblio->{'isbn'};
- $citation .= $biblio->{'isbn'} if $biblio->{'isbn'};
- $citation .= ", " if $biblio->{'issn'} and $biblio->{'isbn'};
- $citation .= $biblio->{'issn'} if $biblio->{'issn'};
- $citation .= ")" if $biblio->{'issn'} or $biblio->{'isbn'};
-
- my $match = GetImportRecordMatches($biblio->{'import_record_id'}, 1);
- my $match_citation = '';
- if ($#$match > -1) {
- $match_citation .= $match->[0]->{'title'} if defined($match->[0]->{'title'});
- $match_citation .= ' ' . $match->[0]->{'author'} if defined($match->[0]->{'author'});
- }
-
- push @list,
- { import_record_id => $biblio->{'import_record_id'},
- final_match_biblionumber => $biblio->{'matched_biblionumber'},
- citation => $citation,
- status => $biblio->{'status'},
- record_sequence => $biblio->{'record_sequence'},
- overlay_status => $biblio->{'overlay_status'},
- match_biblionumber => $#$match > -1 ? $match->[0]->{'biblionumber'} : 0,
- match_citation => $match_citation,
- match_score => $#$match > -1 ? $match->[0]->{'score'} : 0,
- };
- }
- my $num_biblios = $batch->{'num_biblios'};
- $template->param(biblio_list => \@list);
- add_page_numbers($template, $offset, $results_per_page, $num_biblios);
- $template->param(offset => $offset);
- $template->param(range_top => $offset + $results_per_page - 1);
- $template->param(num_results => $num_biblios);
- $template->param(results_per_page => $results_per_page);