|
Lines 89-103
if ( ! $record ) {
Link Here
|
| 89 |
print $query->redirect("/cgi-bin/koha/errors/404.pl"); # escape early |
89 |
print $query->redirect("/cgi-bin/koha/errors/404.pl"); # escape early |
| 90 |
exit; |
90 |
exit; |
| 91 |
} |
91 |
} |
| 92 |
my $framework = &GetFrameworkCode( $biblionumber ); |
92 |
|
|
|
93 |
my $dat = &GetBiblioData($biblionumber); |
| 93 |
my $record_processor = Koha::RecordProcessor->new({ |
94 |
my $record_processor = Koha::RecordProcessor->new({ |
| 94 |
filters => 'ViewPolicy', |
95 |
filters => 'ViewPolicy', |
| 95 |
options => { |
96 |
options => { |
| 96 |
interface => 'opac', |
97 |
interface => 'opac', |
| 97 |
frameworkcode => $framework |
98 |
frameworkcode => $dat->{'frameworkcode'} |
| 98 |
} |
99 |
} |
| 99 |
}); |
100 |
}); |
| 100 |
$record_processor->process($record); |
101 |
|
|
|
102 |
# Only run filtering on record if not XSLT. |
| 103 |
my $xslfile = C4::Context->preference('OPACXSLTDetailsDisplay'); |
| 104 |
if (! $xslfile ) { |
| 105 |
$record_processor->process($record); |
| 106 |
} |
| 101 |
|
107 |
|
| 102 |
# redirect if opacsuppression is enabled and biblio is suppressed |
108 |
# redirect if opacsuppression is enabled and biblio is suppressed |
| 103 |
if (C4::Context->preference('OpacSuppression')) { |
109 |
if (C4::Context->preference('OpacSuppression')) { |
|
Lines 149-155
my $marcflavour = C4::Context->preference("marcflavour");
Link Here
|
| 149 |
my $ean = GetNormalizedEAN( $record, $marcflavour ); |
155 |
my $ean = GetNormalizedEAN( $record, $marcflavour ); |
| 150 |
|
156 |
|
| 151 |
# XSLT processing of some stuff |
157 |
# XSLT processing of some stuff |
| 152 |
my $xslfile = C4::Context->preference('OPACXSLTDetailsDisplay'); |
|
|
| 153 |
my $lang = $xslfile ? C4::Languages::getlanguage() : undef; |
158 |
my $lang = $xslfile ? C4::Languages::getlanguage() : undef; |
| 154 |
my $sysxml = $xslfile ? C4::XSLT::get_xslt_sysprefs() : undef; |
159 |
my $sysxml = $xslfile ? C4::XSLT::get_xslt_sysprefs() : undef; |
| 155 |
|
160 |
|
|
Lines 530-536
if ( C4::Context->preference('HighlightOwnItemsOnOPAC') ) {
Link Here
|
| 530 |
} |
535 |
} |
| 531 |
} |
536 |
} |
| 532 |
|
537 |
|
| 533 |
my $dat = &GetBiblioData($biblionumber); |
|
|
| 534 |
my $HideMARC = $record_processor->filters->[0]->should_hide_marc( |
538 |
my $HideMARC = $record_processor->filters->[0]->should_hide_marc( |
| 535 |
{ |
539 |
{ |
| 536 |
frameworkcode => $dat->{'frameworkcode'}, |
540 |
frameworkcode => $dat->{'frameworkcode'}, |
| 537 |
- |
|
|