|
Lines 57-62
if ( ShelfPossibleAction( (defined($borrowernumber) ? $borrowernumber : -1), $sh
Link Here
|
| 57 |
my ($items, $totitems) = GetShelfContents($shelfid); |
57 |
my ($items, $totitems) = GetShelfContents($shelfid); |
| 58 |
my $marcflavour = C4::Context->preference('marcflavour'); |
58 |
my $marcflavour = C4::Context->preference('marcflavour'); |
| 59 |
my $output; |
59 |
my $output; |
|
|
60 |
my $extension; |
| 61 |
my $type; |
| 60 |
|
62 |
|
| 61 |
# CSV |
63 |
# CSV |
| 62 |
if ($format =~ /^\d+$/) { |
64 |
if ($format =~ /^\d+$/) { |
|
Lines 83-88
if ( ShelfPossibleAction( (defined($borrowernumber) ? $borrowernumber : -1), $sh
Link Here
|
| 83 |
elsif ($format eq 'bibtex') { |
85 |
elsif ($format eq 'bibtex') { |
| 84 |
$output .= marc2bibtex($record, $biblionumber); |
86 |
$output .= marc2bibtex($record, $biblionumber); |
| 85 |
} |
87 |
} |
|
|
88 |
elsif ( $format eq 'isbd' ) { |
| 89 |
$output .= GetISBDView($biblionumber, "opac"); |
| 90 |
$extension = "txt"; |
| 91 |
$type = "text/plain"; |
| 92 |
} |
| 86 |
} |
93 |
} |
| 87 |
} |
94 |
} |
| 88 |
|
95 |
|
|
Lines 90-98
if ( ShelfPossibleAction( (defined($borrowernumber) ? $borrowernumber : -1), $sh
Link Here
|
| 90 |
$format = "csv" if ($format =~ m/^\d+$/); |
97 |
$format = "csv" if ($format =~ m/^\d+$/); |
| 91 |
|
98 |
|
| 92 |
print $query->header( |
99 |
print $query->header( |
| 93 |
-type => 'application/octet-stream', |
100 |
-type => ($type) ? $type : 'application/octet-stream', |
| 94 |
-'Content-Transfer-Encoding' => 'binary', |
101 |
-'Content-Transfer-Encoding' => 'binary', |
| 95 |
-attachment=>"shelf.$format"); |
102 |
-attachment => ($extension) ? "shelf.$format.$extension" : "shelf.$format" |
|
|
103 |
); |
| 96 |
print $output; |
104 |
print $output; |
| 97 |
|
105 |
|
| 98 |
} else { |
106 |
} else { |
| 99 |
- |
|
|