3 # This file is part of Koha.
5 # Koha is free software; you can redistribute it and/or modify it under the
6 # terms of the GNU General Public License as published by the Free Software
7 # Foundation; either version 2 of the License, or (at your option) any later
10 # Koha is distributed in the hope that it will be useful, but WITHOUT ANY
11 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
12 # A PARTICULAR PURPOSE. See the GNU General Public License for more details.
14 # You should have received a copy of the GNU General Public License along with
15 # Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
16 # Suite 330, Boston, MA 02111-1307 USA
23 use C4::Interface::CGI::Output;
28 my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
30 template_name => "barcodes/label-home.tmpl",
34 flagsrequired => { tools => 1 },
39 my $data = get_label_options();
41 my $active_template = GetActiveLabelTemplate();
42 my @label_templates = GetAllLabelTemplates();
44 $template->param( guidebox => 1 ) if ( $data->{'guidebox'} );
46 $data->{'printingtype'} = 'both' if ( !$data->{'printingtype'} );
47 $template->param( "printingtype_$data->{'printingtype'}" => 1 );
48 $template->param( "papertype_$data->{'papertype'}" => 1 );
50 $template->param( "$data->{'barcodetype'}_checked" => 1 );
52 $template->param( "startrow" . $data->{'startrow'} . "_checked" => 1 );
54 itemtype => $data->{'itemtype'},
55 active_template => $data->{'active_template'},
56 label_templates => \@label_templates,
58 papertype => $data->{'papertype'},
59 author => $data->{'author'},
60 barcode => $data->{'barcode'},
62 barcodetype => $data->{'barcodetype'},
63 title => $data->{'title'},
64 isbn => $data->{'isbn'},
65 dewey => $data->{'dewey'},
66 class => $data->{'class'},
67 startrow => $data->{'startrow'},
68 subclass => $data->{'subclass'},
69 itemcallnumber => $data->{'itemcallnumber'},
70 startlabel => $data->{'startlabel'},
71 fontsize => $active_template->{'fontsize'},
73 intranetcolorstylesheet =>
74 C4::Context->preference("intranetcolorstylesheet"),
75 intranetstylesheet => C4::Context->preference("intranetstylesheet"),
76 IntranetNav => C4::Context->preference("IntranetNav"),
79 output_html_with_http_headers $query, $cookie, $template->output;