|
Lines 85-91
if (!C4::Context->userenv && !$branch){
Link Here
|
| 85 |
} |
85 |
} |
| 86 |
|
86 |
|
| 87 |
my $barcodes = []; |
87 |
my $barcodes = []; |
| 88 |
my $batch = $query->param('batch'); |
|
|
| 89 |
if ( my $barcode = $query->param('barcode') ) { |
88 |
if ( my $barcode = $query->param('barcode') ) { |
| 90 |
$barcodes = [ $barcode ]; |
89 |
$barcodes = [ $barcode ]; |
| 91 |
} else { |
90 |
} else { |
|
Lines 105-113
if ( my $barcode = $query->param('barcode') ) {
Link Here
|
| 105 |
|
104 |
|
| 106 |
$barcodes = [ uniq @$barcodes ]; |
105 |
$barcodes = [ uniq @$barcodes ]; |
| 107 |
|
106 |
|
| 108 |
my $template_name = $batch |
107 |
my $template_name = q|circ/circulation.tt|; |
| 109 |
? q|circ/circulation_batch_checkouts.tt| |
108 |
my $borrowernumber = $query->param('borrowernumber'); |
| 110 |
: q|circ/circulation.tt|; |
109 |
my $borrower = $borrowernumber ? GetMember( { borrowernumber => $borrowernumber} ) : undef; |
|
|
110 |
my $batch = $query->param('batch'); |
| 111 |
my $batch_allowed = 0; |
| 112 |
if ( $batch ) { |
| 113 |
$template_name = q|circ/circulation_batch_checkouts.tt|; |
| 114 |
my @batch_category_codes = split '\|', C4::Context->preference('batch_checkouts'); |
| 115 |
if ( grep {/^$borrower->{categorycode}$/} @batch_category_codes ) { |
| 116 |
$batch_allowed = 1; |
| 117 |
} else { |
| 118 |
$barcodes = []; |
| 119 |
} |
| 120 |
} |
| 111 |
|
121 |
|
| 112 |
my ( $template, $loggedinuser, $cookie ) = get_template_and_user ( |
122 |
my ( $template, $loggedinuser, $cookie ) = get_template_and_user ( |
| 113 |
{ |
123 |
{ |
|
Lines 131-137
for (@failedreturns) { $return_failed{$_} = 1; }
Link Here
|
| 131 |
|
141 |
|
| 132 |
my $findborrower = $query->param('findborrower') || q{}; |
142 |
my $findborrower = $query->param('findborrower') || q{}; |
| 133 |
$findborrower =~ s|,| |g; |
143 |
$findborrower =~ s|,| |g; |
| 134 |
my $borrowernumber = $query->param('borrowernumber'); |
|
|
| 135 |
|
144 |
|
| 136 |
$branch = C4::Context->userenv->{'branch'}; |
145 |
$branch = C4::Context->userenv->{'branch'}; |
| 137 |
$printer = C4::Context->userenv->{'branchprinter'}; |
146 |
$printer = C4::Context->userenv->{'branchprinter'}; |
|
Lines 245-251
if ($findborrower) {
Link Here
|
| 245 |
} |
254 |
} |
| 246 |
|
255 |
|
| 247 |
# get the borrower information..... |
256 |
# get the borrower information..... |
| 248 |
my $borrower; |
|
|
| 249 |
if ($borrowernumber) { |
257 |
if ($borrowernumber) { |
| 250 |
$borrower = GetMemberDetails( $borrowernumber, 0 ); |
258 |
$borrower = GetMemberDetails( $borrowernumber, 0 ); |
| 251 |
my ( $od, $issue, $fines ) = GetMemberIssuesAndFines( $borrowernumber ); |
259 |
my ( $od, $issue, $fines ) = GetMemberIssuesAndFines( $borrowernumber ); |
|
Lines 777-782
$template->param(
Link Here
|
| 777 |
inprocess => $inprocess, |
785 |
inprocess => $inprocess, |
| 778 |
is_child => ($borrower->{'category_type'} eq 'C'), |
786 |
is_child => ($borrower->{'category_type'} eq 'C'), |
| 779 |
$view => 1, |
787 |
$view => 1, |
|
|
788 |
batch_allowed => $batch_allowed, |
| 780 |
soundon => C4::Context->preference("SoundOn"), |
789 |
soundon => C4::Context->preference("SoundOn"), |
| 781 |
fast_cataloging => $fast_cataloging, |
790 |
fast_cataloging => $fast_cataloging, |
| 782 |
CircAutoPrintQuickSlip => C4::Context->preference("CircAutoPrintQuickSlip"), |
791 |
CircAutoPrintQuickSlip => C4::Context->preference("CircAutoPrintQuickSlip"), |