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

(-)a/offline_circ/process_koc.pl (-2 / +2 lines)
Lines 78-84 if ($completedJobID) { Link Here
78
78
79
    if ($runinbackground) {
79
    if ($runinbackground) {
80
        my $job_size = scalar(@input_lines);
80
        my $job_size = scalar(@input_lines);
81
        $job = C4::BackgroundJob->new($sessionID, $filename, $ENV{'SCRIPT_NAME'}, $job_size);
81
        $job = C4::BackgroundJob->new($sessionID, $filename, '/cgi-bin/koha/offline_circ/process_koc.pl', $job_size);
82
        my $jobID = $job->id();
82
        my $jobID = $job->id();
83
83
84
        # fork off
84
        # fork off
Lines 104-110 if ($completedJobID) { Link Here
104
        } else {
104
        } else {
105
            # fork failed, so exit immediately
105
            # fork failed, so exit immediately
106
            # fork failed, so exit immediately
106
            # fork failed, so exit immediately
107
            warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
107
            warn "fork failed while attempting to run offline_circ/process_koc.pl as a background job";
108
            exit 0;
108
            exit 0;
109
        }
109
        }
110
110
(-)a/tools/batchMod.pl (-2 / +2 lines)
Lines 671-677 sub add_saved_job_results_to_template { Link Here
671
sub put_in_background {
671
sub put_in_background {
672
    my $job_size = shift;
672
    my $job_size = shift;
673
673
674
    my $job = C4::BackgroundJob->new($sessionID, "test", $ENV{'SCRIPT_NAME'}, $job_size);
674
    my $job = C4::BackgroundJob->new($sessionID, "test", '/cgi-bin/koha/tools/batchMod.pl', $job_size);
675
    my $jobID = $job->id();
675
    my $jobID = $job->id();
676
676
677
    # fork off
677
    # fork off
Lines 696-702 sub put_in_background { Link Here
696
        close STDERR;
696
        close STDERR;
697
    } else {
697
    } else {
698
        # fork failed, so exit immediately
698
        # fork failed, so exit immediately
699
        warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
699
        warn "fork failed while attempting to run tools/batchMod.pl as a background job";
700
        exit 0;
700
        exit 0;
701
    }
701
    }
702
    return $job;
702
    return $job;
(-)a/tools/batch_record_modification.pl (-2 / +2 lines)
Lines 156-162 if ( $op eq 'form' ) { Link Here
156
    my ( $job );
156
    my ( $job );
157
    if ( $runinbackground ) {
157
    if ( $runinbackground ) {
158
        my $job_size = scalar( @record_ids );
158
        my $job_size = scalar( @record_ids );
159
        $job = C4::BackgroundJob->new( $sessionID, "FIXME", $ENV{SCRIPT_NAME}, $job_size );
159
        $job = C4::BackgroundJob->new( $sessionID, "FIXME", '/cgi-bin/koha/tools/batch_record_modification.pl', $job_size );
160
        my $job_id = $job->id;
160
        my $job_id = $job->id;
161
        if (my $pid = fork) {
161
        if (my $pid = fork) {
162
            $dbh->{InactiveDestroy}  = 1;
162
            $dbh->{InactiveDestroy}  = 1;
Lines 169-175 if ( $op eq 'form' ) { Link Here
169
            close STDOUT;
169
            close STDOUT;
170
            close STDERR;
170
            close STDERR;
171
        } else {
171
        } else {
172
            warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
172
            warn "fork failed while attempting to run tools/batch_record_modification.pl as a background job";
173
            exit 0;
173
            exit 0;
174
        }
174
        }
175
    }
175
    }
(-)a/tools/import_borrowers.pl (-1 / +1 lines)
Lines 106-112 if ($matchpoint) { Link Here
106
}
106
}
107
my $overwrite_cardnumber = $input->param('overwrite_cardnumber');
107
my $overwrite_cardnumber = $input->param('overwrite_cardnumber');
108
108
109
$template->param( SCRIPT_NAME => $ENV{'SCRIPT_NAME'} );
109
$template->param( SCRIPT_NAME => '/cgi-bin/koha/tools/import_borrowers.pl' );
110
110
111
if ( $uploadborrowers && length($uploadborrowers) > 0 ) {
111
if ( $uploadborrowers && length($uploadborrowers) > 0 ) {
112
    push @feedback, {feedback=>1, name=>'filename', value=>$uploadborrowers, filename=>$uploadborrowers};
112
    push @feedback, {feedback=>1, name=>'filename', value=>$uploadborrowers, filename=>$uploadborrowers};
(-)a/tools/manage-marc-import.pl (-2 / +2 lines)
Lines 293-299 sub put_in_background { Link Here
293
    my $import_batch_id = shift;
293
    my $import_batch_id = shift;
294
294
295
    my $batch = GetImportBatch($import_batch_id);
295
    my $batch = GetImportBatch($import_batch_id);
296
    my $job = C4::BackgroundJob->new($sessionID, $batch->{'file_name'}, $ENV{'SCRIPT_NAME'}, $batch->{'num_records'});
296
    my $job = C4::BackgroundJob->new($sessionID, $batch->{'file_name'}, '/cgi-bin/koha/tools/manage-marc-import.pl', $batch->{'num_records'});
297
    my $jobID = $job->id();
297
    my $jobID = $job->id();
298
298
299
    # fork off
299
    # fork off
Lines 318-324 sub put_in_background { Link Here
318
        close STDERR;
318
        close STDERR;
319
    } else {
319
    } else {
320
        # fork failed, so exit immediately
320
        # fork failed, so exit immediately
321
        warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
321
        warn "fork failed while attempting to run tools/manage-marc-import.pl as a background job";
322
        exit 0;
322
        exit 0;
323
    }
323
    }
324
    return $job;
324
    return $job;
(-)a/tools/showdiffmarc.pl (-1 / +1 lines)
Lines 85-91 if( $importid ) { Link Here
85
85
86
86
87
$template->param(
87
$template->param(
88
    SCRIPT_NAME      => $ENV{'SCRIPT_NAME'},
88
    SCRIPT_NAME      => '/cgi-bin/koha/tools/showdiffmarc.pl',
89
    BIBLIONUMBER     => $biblionumber,
89
    BIBLIONUMBER     => $biblionumber,
90
    IMPORTID         => $importid,
90
    IMPORTID         => $importid,
91
    BIBLIOTITLE      => $biblioTitle,
91
    BIBLIOTITLE      => $biblioTitle,
(-)a/tools/stage-marc-import.pl (-4 / +3 lines)
Lines 72-78 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
72
);
72
);
73
73
74
$template->param(
74
$template->param(
75
    SCRIPT_NAME => $ENV{'SCRIPT_NAME'},
75
    SCRIPT_NAME => '/cgi-bin/koha/tools/stage-marc-import.pl',
76
    uploadmarc  => $fileID,
76
    uploadmarc  => $fileID,
77
    record_type => $record_type,
77
    record_type => $record_type,
78
);
78
);
Lines 102-108 if ($completedJobID) { Link Here
102
        my $job_size = () = $marcrecord =~ /\035/g;
102
        my $job_size = () = $marcrecord =~ /\035/g;
103
        # if we're matching, job size is doubled
103
        # if we're matching, job size is doubled
104
        $job_size *= 2 if ($matcher_id ne "");
104
        $job_size *= 2 if ($matcher_id ne "");
105
        $job = C4::BackgroundJob->new($sessionID, $filename, $ENV{'SCRIPT_NAME'}, $job_size);
105
        $job = C4::BackgroundJob->new($sessionID, $filename, '/cgi-bin/koha/tools/stage-marc-import.pl', $job_size);
106
        my $jobID = $job->id();
106
        my $jobID = $job->id();
107
107
108
        # fork off
108
        # fork off
Lines 121-127 if ($completedJobID) { Link Here
121
            # close STDERR; # there is no good reason to close STDERR
121
            # close STDERR; # there is no good reason to close STDERR
122
        } else {
122
        } else {
123
            # fork failed, so exit immediately
123
            # fork failed, so exit immediately
124
            warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job: $!";
124
            warn "fork failed while attempting to run tools/stage-marc-import.pl as a background job: $!";
125
            exit 0;
125
            exit 0;
126
        }
126
        }
127
127
128
- 

Return to bug 15005