Bugzilla – Attachment 186305 Details for
Bug 13334
Add a warning when a course reserve is checked in
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 13334: Add warning during the return of a document that was reserved to a course
Bug-13334-Add-warning-during-the-return-of-a-docum.patch (text/plain), 2.77 KB, created by
Blou
on 2025-09-09 21:06:58 UTC
(
hide
)
Description:
Bug 13334: Add warning during the return of a document that was reserved to a course
Filename:
MIME Type:
Creator:
Blou
Created:
2025-09-09 21:06:58 UTC
Size:
2.77 KB
patch
obsolete
>From b7ae7934465f3e19bf945e953717fdbaad257560 Mon Sep 17 00:00:00 2001 >From: simith <simith@inlibro.com> >Date: Thu, 26 Feb 2015 15:35:11 -0500 >Subject: [PATCH] Bug 13334: Add warning during the return of a document that > was reserved to a course > >This patch adds the following warning during the return of a document that was reserved to a course: > >"Please return 'title' to the 'course name' class reserve." > >Testing: > >1) Define a document as a course reserve > >see manual.koha-community.org/3.14/en/coursereserves.html > >2) Checkout and checkin this document. >Validade the warning >--- > circ/returns.pl | 11 ++++++++++- > .../intranet-tmpl/prog/en/modules/circ/returns.tt | 6 ++++++ > 2 files changed, 16 insertions(+), 1 deletion(-) > >diff --git a/circ/returns.pl b/circ/returns.pl >index 901877ef1e..32dd0db1ec 100755 >--- a/circ/returns.pl >+++ b/circ/returns.pl >@@ -42,6 +42,7 @@ use C4::Members; > use C4::Output qw( output_html_with_http_headers ); > use C4::Reserves qw( ModReserve ModReserveAffect CheckReserves ); > use C4::RotatingCollections; >+use C4::CourseReserves; > use Koha::AuthorisedValues; > use Koha::BiblioFrameworks; > use Koha::Calendar; >@@ -388,7 +389,15 @@ if ( $barcode && ( $op eq 'cud-checkin' || $op eq 'cud-affect_reserve' ) ) { > ); > } > } >- >+ # Verify if the item is in the course reserve >+ my $course_reserves = C4::CourseReserves::GetItemCourseReservesInfo( itemnumber => $itemnumber ); >+ if($course_reserves) { >+ $template->param( >+ found => 1, >+ course_reserve => 1, >+ course_name => $course_reserves->[0]->{course}->{course_name} >+ ); >+ } > } elsif ( C4::Context->preference('ShowAllCheckins') > and !$messages->{'BadBarcode'} > and !$needs_confirm >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt >index e52eeae793..b6fb9a4d75 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/returns.tt >@@ -773,6 +773,12 @@ > <!-- /#hold-found1 --> > [% END # /IF waiting %] > >+ [% IF ( course_reserve ) %] >+ <!-- the item has to be returned to the reserved items --> >+ <div class="alert alert-info"> >+ <h3><a href="/cgi-bin/koha/catalogue/detail.pl?type=intra&biblionumber=[% itembiblionumber%]">[% title or "item" |html %]</a> is part of the [% course_name %] course reserve.</h3> >+ </div> >+ [% END %] > [% IF (transfer || needstransfer) && !(reserved and !recalled and !waitingrecall) %] > [% IF Koha.Preference('TransfersBlockCirc') %] > [% SET div_class='block' %] >-- >2.34.1
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 13334
:
33907
|
36212
|
177312
| 186305