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

(-)a/koha-tmpl/intranet-tmpl/prog/en/includes/patroncards-errors.inc (-8 / +8 lines)
Lines 5-21 Link Here
5
[% BLOCK b_layout %]<span>Layout: </span>[% END %]
5
[% BLOCK b_layout %]<span>Layout: </span>[% END %]
6
[% BLOCK b_template %]<span>Template: </span>[% END %]
6
[% BLOCK b_template %]<span>Template: </span>[% END %]
7
7
8
[% IF ( error || CGI.param('pdferr') )  %]
8
[% IF ( error || error_pdferr )  %]
9
<div class="dialog alert">
9
<div class="dialog alert">
10
  <p>
10
  <p>
11
    <strong>WARNING:</strong>
11
    <strong>WARNING:</strong>
12
        [% IF CGI.param('pdferr') %]<span>Error while creating PDF file. </span>
12
        [% IF error_pdferr %]<span>Error while creating PDF file. </span>
13
            [% IF CGI.param('errnocards') %]<span>No cards created (empty batch or list?) </span>[% END %]
13
            [% IF error_errnocards %]<span>No cards created (empty batch or list?) </span>[% END %]
14
            [% IF CGI.param('errba') %][% INCLUDE b_batch %]<span class="ex">[%- CGI.param('errba') | html -%]</span>[% END %]
14
            [% IF error_errba %][% INCLUDE b_batch %]<span class="ex">[%- error_errba | html -%]</span>[% END %]
15
            [% IF CGI.param('errpl') %][% INCLUDE b_patronlist %]<span class="ex">[%- CGI.param('errpl') | html -%]</span>][% END %]
15
            [% IF error_errpl %][% INCLUDE b_patronlist %]<span class="ex">[%- error_errpl | html -%]</span>][% END %]
16
            [% IF CGI.param('errpt') %][% INCLUDE b_patronnumber %]<span class="ex">[%- CGI.param('errpt') | html -%]</span>[% END %]
16
            [% IF error_errpt %][% INCLUDE b_patronnumber %]<span class="ex">[%- error_errpt | html -%]</span>[% END %]
17
            [% IF CGI.param('errlo') %][% INCLUDE b_layout %]<span class="ex">[%- CGI.param('errlo') | html -%]</span>[% END %]
17
            [% IF error_errlo %][% INCLUDE b_layout %]<span class="ex">[%- error_errlo | html -%]</span>[% END %]
18
            [% IF CGI.param('errtpl') %][% INCLUDE b_template %]<span class="ex">[%- CGI.param('errtpl') | html -%]</span>[% END %]
18
            [% IF error_errtpl %][% INCLUDE b_template %]<span class="ex">[%- error_errtpl | html -%]</span>[% END %]
19
            [% INCLUDE asksysadmin %]
19
            [% INCLUDE asksysadmin %]
20
        [% END %]
20
        [% END %]
21
21
(-)a/patroncards/edit-batch.pl (+7 lines)
Lines 61-66 my $errstr = $cgi->param('error') || ''; Link Here
61
my $bor_num_list = $cgi->param('bor_num_list') || undef;
61
my $bor_num_list = $cgi->param('bor_num_list') || undef;
62
my $branch_code = C4::Context->userenv->{'branch'};
62
my $branch_code = C4::Context->userenv->{'branch'};
63
63
64
my @errors = ( 'pdferr', 'errnocards', 'errba', 'errpl', 'errpt', 'errlo', 'errtpl', );
65
foreach my $param (@errors) {
66
    my $error = $cgi->param($param) ? 1 : 0;
67
    $template->param( 'error_' . $param => $error )
68
      if $error;
69
}
70
64
if ($op eq 'remove') {
71
if ($op eq 'remove') {
65
    $batch = C4::Patroncards::Batch->retrieve(batch_id => $batch_id);
72
    $batch = C4::Patroncards::Batch->retrieve(batch_id => $batch_id);
66
    foreach my $label_id (@label_ids) {
73
    foreach my $label_id (@label_ids) {
(-)a/patroncards/image-manage.pl (+7 lines)
Lines 26-31 my $upload_file = $cgi->upload('uploadfile') || ''; Link Here
26
my $op = $cgi->param('op') || 'none';
26
my $op = $cgi->param('op') || 'none';
27
my @image_ids = $cgi->multi_param('image_id');
27
my @image_ids = $cgi->multi_param('image_id');
28
28
29
my @errors = ( 'pdferr', 'errnocards', 'errba', 'errpl', 'errpt', 'errlo', 'errtpl', );
30
foreach my $param (@errors) {
31
    my $error = $cgi->param($param) ? 1 : 0;
32
    $template->param( 'error_' . $param => $error )
33
      if $error;
34
}
35
29
my $source_file = "$file_name"; # otherwise we end up with what amounts to a pointer to a filehandle rather than a user-friendly filename
36
my $source_file = "$file_name"; # otherwise we end up with what amounts to a pointer to a filehandle rather than a user-friendly filename
30
37
31
my $display_columns = { image =>    [  #{db column      => {label => 'col label', is link?          }},
38
my $display_columns = { image =>    [  #{db column      => {label => 'col label', is link?          }},
(-)a/patroncards/manage.pl (-1 / +7 lines)
Lines 45-50 my ( $template, $loggedinuser, $cookie ) = get_template_and_user( Link Here
45
    }
45
    }
46
);
46
);
47
47
48
my @errors = ( 'pdferr', 'errnocards', 'errba', 'errpl', 'errpt', 'errlo', 'errtpl', );
49
foreach my $param (@errors) {
50
    my $error = $cgi->param($param) ? 1 : 0;
51
    $template->param( 'error_' . $param => $error )
52
      if $error;
53
}
54
48
my $op = $cgi->param('op') || 'none';
55
my $op = $cgi->param('op') || 'none';
49
my $card_element = $cgi->param('card_element') || 'template';   # default to template management
56
my $card_element = $cgi->param('card_element') || 'template';   # default to template management
50
my $element_id = $cgi->param('element_id') || 0; # there should never be an element with a id of 0 so this is a safe default
57
my $element_id = $cgi->param('element_id') || 0; # there should never be an element with a id of 0 so this is a safe default
51
- 

Return to bug 18320