];
my $op = $cgi->param('op') || 'new';
my $batch_id = $cgi->param('element_id') || $cgi->param('batch_id') || 0;
+my $description = $cgi->param('description') || '';
my ( @label_ids, @item_numbers, @borrower_numbers );
@label_ids = $cgi->multi_param('label_id') if $cgi->param('label_id');
@item_numbers = $cgi->multi_param('item_number') if $cgi->param('item_number');
}
if ($batch_id != 0) {$batch = C4::Patroncards::Batch->retrieve(batch_id => $batch_id);}
if ($batch_id == 0 || $batch == -2) {$batch = C4::Patroncards::Batch->new(branch_code => $branch_code);}
+ $template->param( description => $batch->{'description'} );
if ($branch_code){
foreach my $borrower_number (@borrower_numbers) {
$err = $batch->add_item($borrower_number);
}
elsif ($op eq 'edit') {
$batch = C4::Patroncards::Batch->retrieve(batch_id => $batch_id);
+ $template->param( description => $batch->{'description'} );
}
elsif ($op eq 'new') {
if ($branch_code eq '') {