Bugzilla – Attachment 135741 Details for
Bug 30823
Recalls should use 'FILL' in action logs
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 30823: Filling recalls uses 'FILL' action in action logs
Bug-30823-Filling-recalls-uses-FILL-action-in-acti.patch (text/plain), 5.70 KB, created by
Aleisha Amohia
on 2022-06-07 00:05:38 UTC
(
hide
)
Description:
Bug 30823: Filling recalls uses 'FILL' action in action logs
Filename:
MIME Type:
Creator:
Aleisha Amohia
Created:
2022-06-07 00:05:38 UTC
Size:
5.70 KB
patch
obsolete
>From 28652a8ce4cda1ad6f2c5bfb3752e752d8102feb Mon Sep 17 00:00:00 2001 >From: Aleisha Amohia <aleishaamohia@hotmail.com> >Date: Mon, 6 Jun 2022 23:52:59 +0000 >Subject: [PATCH] Bug 30823: Filling recalls uses 'FILL' action in action logs > >This enhancement changes recall fulfillment actions to log with the >FILL action. It will also update existing recalls FULFILL actions in >the database to use the FILL action. > >To test: >1) Enable the UseRecalls system preference and set up your >recalls-related circulation rules. Confirm RecallsLog is enabled. >2) Check out an item to Patron B. >3) Log into the OPAC as Patron A and search for the item. >4) Place a recall on that item. >5) Go back to the staff client and check the item in. Confirm the recall >as waiting for Patron A. >6) Check out the item for Patron A to fill the recall. >7) Go to Tools -> Log Viewer. Confirm there is a FULFILL action. Choose >the following search params to browse system logs: >- modules: recalls >- actions: fill >8) Submit the search and confirm the recall DOES NOT show. >9) Apply the patch, update database, restart services. >10) Refresh the log viewer and repeat step 7. Submit the search and >confirm the recall DOES show. Confirm there is no longer a FULFILL >action as both holds and recalls will use FILL. >11) Check in the item. >12) Repeat steps 2-6. We are ensuring that future recalls are logged >using the FILL action. >13) Repeat step 7. Confirm all test recalls are now showing in search >results. > >Sponsored-by: Catalyst IT >--- > Koha/Recall.pm | 2 +- > .../bug_30823_-_update_recalls_FULFILL_actions.pl | 12 ++++++++++++ > koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt | 3 +-- > 3 files changed, 14 insertions(+), 3 deletions(-) > create mode 100644 installer/data/mysql/atomicupdate/bug_30823_-_update_recalls_FULFILL_actions.pl > >diff --git a/Koha/Recall.pm b/Koha/Recall.pm >index a97e741b64..c993bb7fda 100644 >--- a/Koha/Recall.pm >+++ b/Koha/Recall.pm >@@ -457,7 +457,7 @@ Set a recall as finished. This should only be called when the item allocated to > sub set_fulfilled { > my ( $self ) = @_; > $self->update({ status => 'fulfilled', completed => 1, completed_date => dt_from_string }); >- C4::Log::logaction( 'RECALLS', 'FULFILL', $self->id, "Recall fulfilled", 'INTRANET' ) if ( C4::Context->preference('RecallsLog') ); >+ C4::Log::logaction( 'RECALLS', 'FILL', $self->id, "Recall fulfilled", 'INTRANET' ) if ( C4::Context->preference('RecallsLog') ); > return $self; > } > >diff --git a/installer/data/mysql/atomicupdate/bug_30823_-_update_recalls_FULFILL_actions.pl b/installer/data/mysql/atomicupdate/bug_30823_-_update_recalls_FULFILL_actions.pl >new file mode 100644 >index 0000000000..71cc07a352 >--- /dev/null >+++ b/installer/data/mysql/atomicupdate/bug_30823_-_update_recalls_FULFILL_actions.pl >@@ -0,0 +1,12 @@ >+use Modern::Perl; >+ >+return { >+ bug_number => "30823", >+ description => "Replace recalls FULFILL actions with FILL in action logs", >+ up => sub { >+ my ($args) = @_; >+ my ($dbh, $out) = @$args{qw(dbh out)}; >+ >+ $dbh->do(q{ UPDATE action_logs SET action = 'FILL' WHERE action = 'FULFILL' AND module = 'RECALLS' }); >+ }, >+}; >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt >index a5881d04a5..f9dbea05cd 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/tools/viewlog.tt >@@ -145,7 +145,6 @@ > [% CASE 'SERIAL CLAIM' %]<span>Serial claim</span> > [% CASE 'ACQUISITION CLAIM' %]<span>Acquisition claim</span> > [% CASE 'ACQUISITION ORDER' %]<span>Acquisition order</span> >-[% CASE 'FULFILL' %]<span>Fulfill</span> > [% CASE 'OVERDUE' %]<span>Overdue</span> > [% CASE 'EXPIRE' %]<span>Expire</span> > [% CASE %][% action | html %] >@@ -240,7 +239,7 @@ > <label for="actionALL" class="viewlog"><input type="checkbox" id="actionALL" name="actions" value=""> All</label> > [% END %] > >- [% FOREACH actx IN [ 'ADD' 'DELETE' 'MODIFY' 'ISSUE' 'RETURN' 'RENEW' 'CREATE' 'CANCEL' 'FILL' 'SUSPEND' 'RESUME' 'ADDCIRCMESSAGE' 'DELCIRCMESSAGE' 'STATUS_CHANGE' 'PATRON_NOTICE' 'CHANGE PASS' 'Run' 'EDIT_MAPPINGS' 'RESET_MAPPINGS' 'ADD_BASKET' 'MODIFY_BASKET' 'MODIFY_BASKET_HEADER' 'MODIFY_BASKET_USERS' 'CLOSE_BASKET' 'APPROVE_BASKET' 'REOPEN_BASKET' 'CANCEL_ORDER' 'CREATE_ORDER' 'MODIFY_ORDER' 'CREATE_INVOICE_ADJUSTMENT' 'UPDATE_INVOICE_ADJUSTMENT' 'DELETE_INVOICE_ADJUSTMENT' 'RECEIVE_ORDER' 'MODIFY_BUDGET' 'MODIFY_FUND' 'CREATE_FUND' 'DELETE_FUND' 'OVERDUE' 'EXPIRE' 'FULFILL' ] %] >+ [% FOREACH actx IN [ 'ADD' 'DELETE' 'MODIFY' 'ISSUE' 'RETURN' 'RENEW' 'CREATE' 'CANCEL' 'FILL' 'SUSPEND' 'RESUME' 'ADDCIRCMESSAGE' 'DELCIRCMESSAGE' 'STATUS_CHANGE' 'PATRON_NOTICE' 'CHANGE PASS' 'Run' 'EDIT_MAPPINGS' 'RESET_MAPPINGS' 'ADD_BASKET' 'MODIFY_BASKET' 'MODIFY_BASKET_HEADER' 'MODIFY_BASKET_USERS' 'CLOSE_BASKET' 'APPROVE_BASKET' 'REOPEN_BASKET' 'CANCEL_ORDER' 'CREATE_ORDER' 'MODIFY_ORDER' 'CREATE_INVOICE_ADJUSTMENT' 'UPDATE_INVOICE_ADJUSTMENT' 'DELETE_INVOICE_ADJUSTMENT' 'RECEIVE_ORDER' 'MODIFY_BUDGET' 'MODIFY_FUND' 'CREATE_FUND' 'DELETE_FUND' 'OVERDUE' 'EXPIRE' ] %] > [% IF actions.grep(actx).size %] > <label for="action[% actx| replace('\s+', '_') | html %]" class="viewlog"><input type="checkbox" id="action[% actx | replace('\s+', '_') | html %]" name="actions" value="[% actx | html %]" checked="checked"> [% PROCESS translate_log_action action=actx %]</label> > [% ELSE %] >-- >2.11.0
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 30823
:
135741
|
136212
|
137037