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

(-)a/Koha/pdfformat/layout1page.pm (+11 lines)
Lines 140-145 sub printhead { Link Here
140
    my $billing_library  = Koha::Libraries->find( $basketgroup->{billingplace} );
140
    my $billing_library  = Koha::Libraries->find( $basketgroup->{billingplace} );
141
    my $delivery_library = Koha::Libraries->find( $basketgroup->{deliveryplace} );
141
    my $delivery_library = Koha::Libraries->find( $basketgroup->{deliveryplace} );
142
    my $freedeliveryplace = $basketgroup->{freedeliveryplace};
142
    my $freedeliveryplace = $basketgroup->{freedeliveryplace};
143
    my $ordersentences = C4::Context->preference("1PageOrderPDFText");
143
144
144
    # open 1st page (with the header)
145
    # open 1st page (with the header)
145
    my $page = $pdf->openpage(1);
146
    my $page = $pdf->openpage(1);
Lines 162-167 sub printhead { Link Here
162
    $text->translate(107/mm, ($height-67)/mm);
163
    $text->translate(107/mm, ($height-67)/mm);
163
    $text->text($libraryname);
164
    $text->text($libraryname);
164
165
166
    # print text defined in 1PageOrderPDFText syspref
167
    $text->font( $pdf->corefont("Times", -encoding => "utf8"), 4/mm );
168
    my @allLines = split/\n+/, $ordersentences;
169
    my $count = 0;
170
    foreach my $ordersentence ( @allLines ) {
171
        $count+=4;
172
        $text->translate(15/mm, ($height-(105 + $count ))/mm);
173
        $text->text( $ordersentence );
174
    }
175
165
    $text->font( $pdf->corefont("Times", -encoding => "utf8"), 4/mm );
176
    $text->font( $pdf->corefont("Times", -encoding => "utf8"), 4/mm );
166
    $text->translate(107/mm, ($height-71)/mm);
177
    $text->translate(107/mm, ($height-71)/mm);
167
    $text->text($billing_library->branchname);
178
    $text->text($billing_library->branchname);
(-)a/installer/data/mysql/atomicupdate/bug_33393-add_1PageOrderPDFText.pl (-4 / +6 lines)
Lines 1-13 Link Here
1
use Modern::Perl;
1
use Modern::Perl;
2
2
3
return {
3
return {
4
    bug_number => "33393",
4
    bug_number  => "33393",
5
    description => "Modify sentence above the order table in English 1-page order PDF",
5
    description => "Modify sentence above the order table in English 1-page order PDF",
6
    up => sub {
6
    up          => sub {
7
        my ($args) = @_;
7
        my ($args) = @_;
8
        my ($dbh, $out) = @$args{qw(dbh out)};
8
        my ( $dbh, $out ) = @$args{qw(dbh out)};
9
9
10
        $dbh->do(q{INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES ('1PageOrderPDFText', 'Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if \n you are unable to supply item(s).', NULL, 'Text to be used above the order table in the 1-page order PDF file', 'textarea') });
10
        $dbh->do(
11
            q{INSERT IGNORE INTO systempreferences (variable,value,options,explanation,type) VALUES ('1PageOrderPDFText', 'Order number must appear on all related correspondence, shipping papers and invoices. Notify us immediately if \n you are unable to supply item(s).', NULL, 'Text to be used above the order table in the 1-page order PDF file', 'textarea') }
12
        );
11
13
12
        say $out "Added system preference '1PageOrderPDFText'";
14
        say $out "Added system preference '1PageOrderPDFText'";
13
    },
15
    },

Return to bug 33393