my $runinbackground = $input->param('runinbackground');
my $completedJobID = $input->param('completedJobID');
my $matcher_id = $input->param('matcher');
+my $overlay_action = $input->param('overlay_action');
+my $nomatch_action = $input->param('nomatch_action');
my $parse_items = $input->param('parse_items');
+my $item_action = $input->param('item_action');
my $comments = $input->param('comments');
my $syntax = $input->param('syntax');
my ($template, $loggedinuser, $cookie)
query => $input,
type => "intranet",
authnotrequired => 0,
- flagsrequired => {tools => 1},
+ flagsrequired => {tools => 'stage_marc_import'},
debug => 1,
});
my $uploaded_file = C4::UploadedFile->fetch($sessionID, $fileID);
my $fh = $uploaded_file->fh();
my $marcrecord='';
+ $/ = "\035";
while (<$fh>) {
+ s/^\s+//;
+ s/\s+$//;
$marcrecord.=$_;
}
if (defined $matcher) {
$checked_matches = 1;
$matcher_code = $matcher->code();
- $num_with_matches = BatchFindBibDuplicates($batch_id, $matcher, 10, 50, matching_progress_callback($job, $dbh));
+ $num_with_matches = BatchFindBibDuplicates($batch_id, $matcher,
+ 10, 50, matching_progress_callback($job, $dbh));
SetImportBatchMatcher($batch_id, $matcher_id);
+ SetImportBatchOverlayAction($batch_id, $overlay_action);
+ SetImportBatchNoMatchAction($batch_id, $nomatch_action);
+ SetImportBatchItemAction($batch_id, $item_action);
$dbh->commit();
} else {
$matcher_failed = 1;
} else {
# initial form
+ if (C4::Context->preference("marcflavour") eq "UNIMARC") {
+ $template->param("UNIMARC" => 1);
+ }
my @matchers = C4::Matcher::GetMatcherList();
$template->param(available_matchers => \@matchers);
}