Bug 20421 - Apply CheckPrevCheckout logic when placing a hold on the staff client
Summary: Apply CheckPrevCheckout logic when placing a hold on the staff client
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Hold requests (show other bugs)
Version: Main
Hardware: All All
: P5 - low enhancement
Assignee: Josef Moravec
QA Contact: Katrin Fischer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-03-15 11:34 UTC by Josef Moravec
Modified: 2022-04-06 13:11 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
This enhancement will now warn staff when placing a hold on an item that a borrower has previously checked out. Will only be displayed if CheckPrevCheckout system preference is enabled.
Version(s) released in:
19.05.00
Circulation function:


Attachments
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.65 KB, patch)
2018-03-15 11:51 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.83 KB, patch)
2018-07-02 09:38 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.75 KB, patch)
2019-03-06 12:47 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.79 KB, patch)
2019-03-06 12:55 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.84 KB, patch)
2019-03-14 12:26 UTC, Martin Renvoize (ashimema)
Details | Diff | Splinter Review
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.88 KB, patch)
2019-03-15 20:04 UTC, Bin Wen
Details | Diff | Splinter Review
Bug 20421: (follow-up) Fix styling (1.07 KB, patch)
2019-04-15 13:04 UTC, Josef Moravec
Details | Diff | Splinter Review
Bug 20421: Inform staff that patron does have the title checked out during placing hold (5.95 KB, patch)
2019-04-25 06:25 UTC, Katrin Fischer
Details | Diff | Splinter Review
Bug 20421: (follow-up) Fix styling (1.12 KB, patch)
2019-04-25 06:25 UTC, Katrin Fischer
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Josef Moravec 2018-03-15 11:34:53 UTC

    
Comment 1 Josef Moravec 2018-03-15 11:51:10 UTC
Created attachment 72935 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles
Comment 2 Cab Vinton 2018-07-02 08:14:52 UTC
Received the following error message on attempting to place a hold:

Software error:
Global symbol "$multihold" requires explicit package name (did you forget to declare "my $multihold"?) at /home/koha/src/reserve/request.pl line 374.
Execution of /home/koha/src/reserve/request.pl aborted due to compilation errors.

Tested in Sandbox 06.

Apologies if my testing went off the rails. First attempt to sign off on a patch.
Comment 3 Josef Moravec 2018-07-02 09:38:15 UTC
Created attachment 76611 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles
Comment 4 Josef Moravec 2018-07-02 09:40:01 UTC
(In reply to Cab Vinton from comment #2)
> Received the following error message on attempting to place a hold:
> 
> Software error:
> Global symbol "$multihold" requires explicit package name (did you forget to
> declare "my $multihold"?) at /home/koha/src/reserve/request.pl line 374.
> Execution of /home/koha/src/reserve/request.pl aborted due to compilation
> errors.
> 
> Tested in Sandbox 06.
> 
> Apologies if my testing went off the rails. First attempt to sign off on a
> patch.

My bad, now it is corrected and rebased on master, you can try it again.
Comment 5 Cab Vinton 2018-07-02 11:14:52 UTC
All good now :-)

Cheers.
Comment 6 Katrin Fischer 2018-07-08 12:37:50 UTC
Patch doesn't apply, can you please rebase?
Comment 7 Josef Moravec 2019-03-06 12:47:54 UTC
Created attachment 86133 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles
Comment 8 Josef Moravec 2019-03-06 12:55:36 UTC
Created attachment 86150 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles
Comment 9 Josef Moravec 2019-03-06 13:00:25 UTC
Rebased on master
Comment 10 Martin Renvoize (ashimema) 2019-03-14 12:26:22 UTC
Created attachment 86598 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Comment 11 Martin Renvoize (ashimema) 2019-03-14 12:26:54 UTC
Works as described, signing off.
Comment 12 Josef Moravec 2019-03-15 07:35:38 UTC
(In reply to Martin Renvoize from comment #11)
> Works as described, signing off.

Thanks Martin
Comment 13 Bin Wen 2019-03-15 20:04:33 UTC
Created attachment 86691 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Bin Wen <bin.wen@inlibro.com>
Comment 14 Katrin Fischer 2019-04-10 10:19:03 UTC
The information in the new column displays in a big yellow box that overlaps the borders of the box. Hopefully an easy fix, otherwise works well!
Comment 15 Josef Moravec 2019-04-15 13:04:42 UTC
Created attachment 88002 [details] [review]
Bug 20421: (follow-up) Fix styling

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Comment 16 Josef Moravec 2019-04-15 13:12:45 UTC
(In reply to Katrin Fischer from comment #14)
> The information in the new column displays in a big yellow box that overlaps
> the borders of the box. Hopefully an easy fix, otherwise works well!

Fixed in follow-up
Comment 17 Katrin Fischer 2019-04-25 06:25:50 UTC
Created attachment 88686 [details] [review]
Bug 20421: Inform staff that patron does have the title checked out during placing hold

Test plan:
1) Enable the CheckPrevCheckout and DisplayMultiPlaceHold system preferences
2) Have a patron with some checkouts history
3) Try to place hold on one of titles from history for this patron
4) You should see an information at the top of confirm request page, but
you still should be able to place a hold
5) Try this with multiple titles - one or more of them should be from
history
6) You should see this information in "Information" column
7) There is also new column placed at the beggining with checkbox, you
could uncheck it for titles you do not want to place a hold on it
8) Confirm the hold is placed only on checked titles

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Bin Wen <bin.wen@inlibro.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 18 Katrin Fischer 2019-04-25 06:25:54 UTC
Created attachment 88687 [details] [review]
Bug 20421: (follow-up) Fix styling

Signed-off-by: Josef Moravec <josef.moravec@gmail.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 19 Nick Clemens (kidclamp) 2019-04-29 16:20:03 UTC
Awesome work all!

Pushed to master for 19.05
Comment 20 Martin Renvoize (ashimema) 2019-05-08 14:07:05 UTC
Enhancement will not be backported to 18.11.x series.