Bugzilla – Attachment 141207 Details for
Bug 30944
Fix single cancel recall button in recalls tab in staff interface and correctly handle cancellations with branch transfers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30944: Fix cancel recalls actions
Bug-30944-Fix-cancel-recalls-actions.patch (text/plain), 7.22 KB, created by
Katrin Fischer
on 2022-10-02 10:52:52 UTC
(
hide
)
Description:
Bug 30944: Fix cancel recalls actions
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2022-10-02 10:52:52 UTC
Size:
7.22 KB
patch
obsolete
>From 52448b5206a786ee9a48b73b5f70f0ae3039e527 Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Thu, 11 Aug 2022 17:29:04 +1200 >Subject: [PATCH] Bug 30944: Fix cancel recalls actions > >This patch fixes the 'cancel selected recalls' button on the biblio >details Recalls page, and ensures a correct cancellation reason is >logged when cancelling a recall in transit. > >To test: >1) Ensure UseRecalls is enabled and relevant recalls circulation rules >are set >2) Check out Item A to Patron B >3) Log into OPAC as Patron A >4) Search for Item A and place a recall >5) Go back to the staff interface and search for Item A. When viewing >the biblio record, go to the recalls tab. >6) Check the checkbox for your recall, and click the button to cancel >selected recalls. >7) Confirm your recall is successfully removed and you're redirected to >the correct recalls page for this biblio. >8) Go back to the OPAC and place a recall again. This time set the >pickup location to a different library, one that you're not logged in at >9) Back in the staff interface, check in Item A and confirm the recall >and transfer >10) Go to Circulation -> Recalls to pull. Your recall should show here. >Click the button to cancel the recall and revert the transfer >11) Confirm the recall has been cancelled >12) Go to Reports and create a new SQL report with the following SQL: >select * from branchtransfers b join items i on >b.itemnumber=i.itemnumber where i.barcode = <<barcode>> >13) Run the report and paste the barcode of Item A in the field >14) Confirm there are two rows returned - the transfer triggered when >the recall was confirmed, with a reason of 'Recall' and a cancellation >reason of 'RecallCancellation, and the transfer sending the item back >home when the recall was cancelled, with a reason of >'RecallCancellation'. > >Sponsored-by: Catalyst IT > >Signed-off-by: David Nind <david@davidnind.com> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > ...ellation_branchtransfers.cancellation_reason.pl | 14 ++++++++++++++ > installer/data/mysql/kohastructure.sql | 2 +- > .../prog/en/modules/recalls/request.tt | 1 + > koha-tmpl/opac-tmpl/bootstrap/en/modules/ilsdi.tt | 2 +- > opac/ilsdi.pl | 2 +- > 5 files changed, 18 insertions(+), 3 deletions(-) > create mode 100644 installer/data/mysql/atomicupdate/bug_30944_-_fix_RecallCancellation_branchtransfers.cancellation_reason.pl > >diff --git a/installer/data/mysql/atomicupdate/bug_30944_-_fix_RecallCancellation_branchtransfers.cancellation_reason.pl b/installer/data/mysql/atomicupdate/bug_30944_-_fix_RecallCancellation_branchtransfers.cancellation_reason.pl >new file mode 100644 >index 0000000000..f42487360c >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_30944_-_fix_RecallCancellation_branchtransfers.cancellation_reason.pl >@@ -0,0 +1,14 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => "30944", >+ description => "Replace branchtransfers.cancellation_reason CancelRecall with RecallCancellation", >+ up => sub { >+ my ($args) = @_; >+ my ($dbh, $out) = @$args{qw(dbh out)}; >+ >+ $dbh->do(q{ >+ ALTER TABLE branchtransfers MODIFY COLUMN cancellation_reason ENUM('Manual','StockrotationAdvance','StockrotationRepatriation','ReturnToHome','ReturnToHolding','RotatingCollection','Reserve','LostReserve','CancelReserve','ItemLost','WrongTransfer','RecallCancellation') COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'what triggered the transfer cancellation' >+ }); >+ }, >+}; >diff --git a/installer/data/mysql/kohastructure.sql b/installer/data/mysql/kohastructure.sql >index ce0c4eacc5..b3f8675ccd 100644 >--- a/installer/data/mysql/kohastructure.sql >+++ b/installer/data/mysql/kohastructure.sql >@@ -1573,7 +1573,7 @@ CREATE TABLE `branchtransfers` ( > `tobranch` varchar(10) COLLATE utf8mb4_unicode_ci NOT NULL DEFAULT '' COMMENT 'the branch the transfer was going to', > `comments` longtext COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'any comments related to the transfer', > `reason` ENUM('Manual','StockrotationAdvance','StockrotationRepatriation','ReturnToHome','ReturnToHolding','RotatingCollection','Reserve','LostReserve','CancelReserve','TransferCancellation','Recall','RecallCancellation') COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'what triggered the transfer', >- `cancellation_reason` enum('Manual','StockrotationAdvance','StockrotationRepatriation','ReturnToHome','ReturnToHolding','RotatingCollection','Reserve','LostReserve','CancelReserve','ItemLost','WrongTransfer','CancelRecall') COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'what triggered the transfer cancellation', >+ `cancellation_reason` enum('Manual','StockrotationAdvance','StockrotationRepatriation','ReturnToHome','ReturnToHolding','RotatingCollection','Reserve','LostReserve','CancelReserve','ItemLost','WrongTransfer','RecallCancellation') COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT 'what triggered the transfer cancellation', > PRIMARY KEY (`branchtransfer_id`), > KEY `frombranch` (`frombranch`), > KEY `tobranch` (`tobranch`), >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/recalls/request.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/recalls/request.tt >index 2f4a573cf8..3fcc9d8ea9 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/recalls/request.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/recalls/request.tt >@@ -29,6 +29,7 @@ > [% IF recalls.count %] > <form method="post" action="/cgi-bin/koha/recalls/request.pl"> > <input type="hidden" name="op" value="cancel_multiple_recalls"> >+ <input type="hidden" name="biblionumber" value="[% biblio.biblionumber | html %]"> > <input type="checkbox" id="select_all"> <span id="select_all_text">Select all</span> > [% INCLUDE 'recalls.inc' %] > <fieldset class="action"> >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/ilsdi.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/ilsdi.tt >index 5af7fdf14f..86d205ccf9 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/ilsdi.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/ilsdi.tt >@@ -857,7 +857,7 @@ > <li><a href="ilsdi.pl?service=Describe&verb=HoldItem">HoldItem</a></li> > <li><a href="ilsdi.pl?service=Describe&verb=CancelHold">CancelHold</a></li> > <li>RecallItem <em>(Not supported by Koha)</em></li> >- <li>CancelRecall <em>(Not supported by Koha)</em></li> >+ <li>RecallCancellation <em>(Not supported by Koha)</em></li> > </ul> > > <h2>Level 4: Robust/domain specific discovery platforms</h2> >diff --git a/opac/ilsdi.pl b/opac/ilsdi.pl >index 5b105246fa..ba38727b84 100755 >--- a/opac/ilsdi.pl >+++ b/opac/ilsdi.pl >@@ -74,7 +74,7 @@ my @services = ( > 'CancelHold', > > # 'RecallItem', # Not supported by Koha >- # 'CancelRecall', # Not supported by Koha >+ # 'RecallCancellation', # Not supported by Koha > # Level 4: Robust/domain specific discovery platforms > # 'SearchCourseReserves', # TODO > # 'Explain' # TODO >-- >2.30.2
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 30944
:
139012
|
139034
|
140411
| 141207 |
141208