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

(-)a/Koha/OAI/Harvester/Worker/Download/Stream.pm (-2 / +5 lines)
Lines 19-25 package Koha::OAI::Harvester::Worker::Download::Stream; Link Here
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use LWP::UserAgent;
21
use LWP::UserAgent;
22
use UUID qw/uuid/;
22
use UUID;
23
use POE;
23
use POE;
24
use JSON;
24
use JSON;
25
use File::Path qw/make_path/;
25
use File::Path qw/make_path/;
Lines 134-140 sub do_work { Link Here
134
                    if ( ! -d $spooldir ){
134
                    if ( ! -d $spooldir ){
135
                        my $made_spool_directory = make_path($spooldir);
135
                        my $made_spool_directory = make_path($spooldir);
136
                    }
136
                    }
137
                    my $file_uuid = uuid();
137
                    my ($uuid,$uuid_string);
138
                    UUID::generate($uuid);
139
                    UUID::unparse($uuid, $uuid_string);
140
                    my $file_uuid = $uuid_string;
138
                    my $filename = "$spooldir/$file_uuid";
141
                    my $filename = "$spooldir/$file_uuid";
139
                    my $state = $document->toFile($filename, 2);
142
                    my $state = $document->toFile($filename, 2);
140
                    if ($state){
143
                    if ($state){
(-)a/tools/oai-pmh-harvester/request.pl (-5 / +6 lines)
Lines 18-24 Link Here
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
18
# along with Koha; if not, see <http://www.gnu.org/licenses>.
19
19
20
use Modern::Perl;
20
use Modern::Perl;
21
use UUID qw/uuid/;
21
use UUID;
22
22
23
use C4::Auth;
23
use C4::Auth;
24
use C4::Output;
24
use C4::Output;
Lines 109-116 if ($op eq "new"){ Link Here
109
}
109
}
110
elsif ($op eq "create"){
110
elsif ($op eq "create"){
111
    if ($save){
111
    if ($save){
112
        my $uuid = uuid;
112
        my ($uuid,$uuid_string);
113
        $request->uuid($uuid);
113
        UUID::generate($uuid);
114
        UUID::unparse($uuid, $uuid_string);
115
        $request->uuid($uuid_string);
114
        $request->store;
116
        $request->store;
115
        print $input->redirect('/cgi-bin/koha/tools/oai-pmh-harvester/dashboard.pl#saved_results');
117
        print $input->redirect('/cgi-bin/koha/tools/oai-pmh-harvester/dashboard.pl#saved_results');
116
        exit;
118
        exit;
Lines 139-142 else { Link Here
139
$template->{VARS}->{ op } = $op;
141
$template->{VARS}->{ op } = $op;
140
$template->{VARS}->{ oai_pmh_request } = $request;
142
$template->{VARS}->{ oai_pmh_request } = $request;
141
143
142
output_html_with_http_headers($input, $cookie, $template->output);
144
output_html_with_http_headers($input, $cookie, $template->output);
143
- 

Return to bug 10662