diff --git a/ill/ill-requests.pl b/ill/ill-requests.pl index b388edadd0..02af20935d 100755 --- a/ill/ill-requests.pl +++ b/ill/ill-requests.pl @@ -30,6 +30,7 @@ use Koha::ILL::Requests; use Koha::ILL::Request; use Koha::ILL::Batches; use Koha::ILL::Request::Workflow::Availability; +use Koha::ILL::Request::Workflow::HistoryCheck; use Koha::ILL::Request::Workflow::TypeDisclaimer; use Koha::ILL::Request::Workflow::ConfirmAuto; use Koha::Libraries; @@ -133,12 +134,18 @@ if ($backends_available) { my $request = Koha::ILL::Request->new->load_backend( $params->{backend} ); # Before request creation operations - Preparation + my $history_check = Koha::ILL::Request::Workflow::HistoryCheck->new( $params, 'staff' ); my $availability = Koha::ILL::Request::Workflow::Availability->new( $params, 'staff' ); my $type_disclaimer = Koha::ILL::Request::Workflow::TypeDisclaimer->new( $params, 'staff' ); my $confirm_auto = Koha::ILL::Request::Workflow::ConfirmAuto->new( $params, 'staff' ); - # ILLCheckAvailability operation - if ( $availability->show_availability($request) ) { + # ILLHistoryCheck operation + if ( $history_check->show_history_check($request) ) { + $op = 'historycheck'; + $template->param( $history_check->history_check_template_params($params) ) + + # ILLCheckAvailability operation + } elsif ( $availability->show_availability($request) ) { $op = 'availability'; $template->param( $availability->availability_template_params($params) ) diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt index 2b3f0a3d81..a462ef59d3 100644 --- a/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt +++ b/koha-tmpl/intranet-tmpl/prog/en/modules/ill/ill-requests.tt @@ -65,6 +65,8 @@ [% ELSE %] Confirm request [% END %] + [% ELSIF op == 'historycheck' %] + Request history check [% END %] [% END %] [% END #/ WRAPPER breadcrumbs %] @@ -900,6 +902,71 @@ + [% ELSIF op == 'historycheck' %] + +