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 707-713 sub add_saved_job_results_to_template { Link Here
707
sub put_in_background {
707
sub put_in_background {
708
    my $job_size = shift;
708
    my $job_size = shift;
709
709
710
    my $job = C4::BackgroundJob->new($sessionID, "test", $ENV{'SCRIPT_NAME'}, $job_size);
710
    my $job = C4::BackgroundJob->new($sessionID, "test", '/cgi-bin/koha/tools/batchMod.pl', $job_size);
711
    my $jobID = $job->id();
711
    my $jobID = $job->id();
712
712
713
    # fork off
713
    # fork off
Lines 732-738 sub put_in_background { Link Here
732
        close STDERR;
732
        close STDERR;
733
    } else {
733
    } else {
734
        # fork failed, so exit immediately
734
        # fork failed, so exit immediately
735
        warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job";
735
        warn "fork failed while attempting to run tools/batchMod.pl as a background job";
736
        exit 0;
736
        exit 0;
737
    }
737
    }
738
    return $job;
738
    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 101-107 if ($completedJobID) { Link Here
101
        my $job_size = () = $marcrecord =~ /\035/g;
101
        my $job_size = () = $marcrecord =~ /\035/g;
102
        # if we're matching, job size is doubled
102
        # if we're matching, job size is doubled
103
        $job_size *= 2 if ($matcher_id ne "");
103
        $job_size *= 2 if ($matcher_id ne "");
104
        $job = C4::BackgroundJob->new($sessionID, $filename, $ENV{'SCRIPT_NAME'}, $job_size);
104
        $job = C4::BackgroundJob->new($sessionID, $filename, '/cgi-bin/koha/tools/stage-marc-import.pl', $job_size);
105
        my $jobID = $job->id();
105
        my $jobID = $job->id();
106
106
107
        # fork off
107
        # fork off
Lines 120-126 if ($completedJobID) { Link Here
120
            # close STDERR; # there is no good reason to close STDERR
120
            # close STDERR; # there is no good reason to close STDERR
121
        } else {
121
        } else {
122
            # fork failed, so exit immediately
122
            # fork failed, so exit immediately
123
            warn "fork failed while attempting to run $ENV{'SCRIPT_NAME'} as a background job: $!";
123
            warn "fork failed while attempting to run tools/stage-marc-import.pl as a background job: $!";
124
            exit 0;
124
            exit 0;
125
        }
125
        }
126
126
127
- 

Return to bug 15005