Lines 197-202
if ( $op eq "export" ) {
Link Here
|
197 |
@record_ids = grep $record_ids{$_}, @filter_record_ids; |
197 |
@record_ids = grep $record_ids{$_}, @filter_record_ids; |
198 |
} |
198 |
} |
199 |
|
199 |
|
|
|
200 |
my $export_items_bundle_contents = $query->param('export_items_bundle_contents'); |
201 |
if ($export_items_bundle_contents and $record_type eq 'bibs') { |
202 |
my $schema = Koha::Database->new->schema; |
203 |
my $items_bundle_rs = $schema->resultset('ItemsBundle'); |
204 |
foreach my $record_id (@record_ids) { |
205 |
my $item_bundle = $items_bundle_rs->find({ biblionumber => $record_id }); |
206 |
if ($item_bundle) { |
207 |
foreach my $items_bundle_item ($item_bundle->items_bundle_items) { |
208 |
my $biblionumber = $items_bundle_item->itemnumber->get_column('biblionumber'); |
209 |
my $itemnumber = $items_bundle_item->get_column('itemnumber'); |
210 |
push @record_ids, $biblionumber; |
211 |
push @itemnumbers, $itemnumber; |
212 |
} |
213 |
} |
214 |
} |
215 |
@record_ids = uniq @record_ids; |
216 |
} |
217 |
|
200 |
print CGI->new->header( |
218 |
print CGI->new->header( |
201 |
-type => 'application/octet-stream', |
219 |
-type => 'application/octet-stream', |
202 |
-charset => 'utf-8', |
220 |
-charset => 'utf-8', |
203 |
- |
|
|