Lines 48-53
use C4::Members; # to use GetMember
Link Here
|
48 |
use C4::Serials; # CountSubscriptionFromBiblionumber |
48 |
use C4::Serials; # CountSubscriptionFromBiblionumber |
49 |
use C4::Search; # enabled_staff_search_views |
49 |
use C4::Search; # enabled_staff_search_views |
50 |
use C4::Acquisition qw(GetOrdersByBiblionumber); |
50 |
use C4::Acquisition qw(GetOrdersByBiblionumber); |
|
|
51 |
use Koha::RecordProcessor; |
51 |
|
52 |
|
52 |
|
53 |
|
53 |
#---- Internal function |
54 |
#---- Internal function |
Lines 70-85
my ( $template, $loggedinuser, $cookie ) = get_template_and_user(
Link Here
|
70 |
} |
71 |
} |
71 |
); |
72 |
); |
72 |
|
73 |
|
73 |
my $res = GetISBDView($biblionumber, "intranet"); |
74 |
if ( not defined $biblionumber ) { |
74 |
if ( not defined $res ) { |
|
|
75 |
# biblionumber invalid -> report and exit |
75 |
# biblionumber invalid -> report and exit |
76 |
$template->param( unknownbiblionumber => 1, |
76 |
$template->param( unknownbiblionumber => 1, |
77 |
biblionumber => $biblionumber |
77 |
biblionumber => $biblionumber |
78 |
); |
78 |
); |
79 |
output_html_with_http_headers $query, $cookie, $template->output; |
79 |
output_html_with_http_headers $query, $cookie, $template->output; |
80 |
exit; |
80 |
exit; |
81 |
} |
81 |
} |
82 |
|
82 |
|
|
|
83 |
my $record_unfiltered = GetMarcBiblio($biblionumber,1); |
84 |
my $record_processor = Koha::RecordProcessor->new({ |
85 |
filters => 'ViewPolicy', |
86 |
options => { |
87 |
interface => 'intranet', |
88 |
}, |
89 |
}); |
90 |
my $record_filtered = $record_unfiltered->clone(); |
91 |
my $record = $record_processor->process($record_filtered); |
92 |
|
93 |
if ( not defined $record ) { |
94 |
# biblionumber invalid -> report and exit |
95 |
$template->param( unknownbiblionumber => 1, |
96 |
biblionumber => $biblionumber |
97 |
); |
98 |
output_html_with_http_headers $query, $cookie, $template->output; |
99 |
exit; |
100 |
} |
101 |
|
102 |
my $framework = GetFrameworkCode( $biblionumber ); |
103 |
my $res = GetISBDView({ |
104 |
'record' => $record, |
105 |
'template' => 'intranet', |
106 |
'framework' => $framework, |
107 |
}); |
108 |
|
83 |
if($query->cookie("holdfor")){ |
109 |
if($query->cookie("holdfor")){ |
84 |
my $holdfor_patron = GetMember('borrowernumber' => $query->cookie("holdfor")); |
110 |
my $holdfor_patron = GetMember('borrowernumber' => $query->cookie("holdfor")); |
85 |
$template->param( |
111 |
$template->param( |
Lines 103-109
if ($subscriptionsnumber) {
Link Here
|
103 |
subscriptiontitle => $subscriptiontitle, |
129 |
subscriptiontitle => $subscriptiontitle, |
104 |
); |
130 |
); |
105 |
} |
131 |
} |
106 |
my $record = GetMarcBiblio($biblionumber); |
|
|
107 |
|
132 |
|
108 |
$template->param ( |
133 |
$template->param ( |
109 |
ISBD => $res, |
134 |
ISBD => $res, |