[Bug 31963] New: Only show reserve fee message on OPAC if they will actually be charged
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Bug ID: 31963 Summary: Only show reserve fee message on OPAC if they will actually be charged Change sponsored?: --- Product: Koha Version: 22.05 Hardware: All OS: All Status: NEW Severity: trivial Priority: P5 - low Component: Hold requests Assignee: koha-bugs@lists.koha-community.org Reporter: aleisha@catalyst.net.nz QA Contact: testopia@bugs.koha-community.org CC: gmcharlt@gmail.com Hold fees can be set at the patron-category level, and if a patron who could be charged a reserve fee logs into the OPAC and tries the place a hold, a message about being charged a hold fee will show. This message does not take HoldFeeMode into consideration. When HoldFeeMode is set to "any time a reserve is collected" the message will be "You will be charged a hold fee of $X when you collect this item", but if HoldFeeMode is set to anything else, the message will be what we are seeing "You will be charged a hold fee of $X for placing this hold". This message can be a bit unexpected, especially if HoldFeeMode is set so hold fees should only be charged if all items are checked out and the record has at least one hold already. We don't expect we should see the message if there are items available and no holds on the record, when HoldFeeMode is set this way. -- You are receiving this mail because: You are the assignee for the bug. You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Change sponsored?|--- |Sponsored Assignee|koha-bugs@lists.koha-commun |aleisha@catalyst.net.nz |ity.org | -- You are receiving this mail because: You are watching all bug changes. You are the assignee for the bug.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Version|22.05 |master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |Needs Signoff Patch complexity|--- |Small patch -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 --- Comment #1 from Aleisha Amohia <aleisha@catalyst.net.nz> --- Created attachment 142585 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=142585&action=edit Bug 31963: Only show hold fee msg on OPAC if patron will be charged This patch ensures HoldFeeMode is considered when displaying a message to patrons on the OPAC that says they'll be charged a hold fee when placing or collecting the hold. When HoldFeeMode is set to not_always or "only if all items are checked out and the record has at least one hold already" then the hold fee message should only show if all items on the record are checked out, AND the record has at least one hold already - both of these conditions must be met. To test: 1. Go to Administration -> Patron categories 2. Edit your patron category and give a hold fee of $1. 3. Go to Administration -> System preferences and search for HoldFeeMode. Set to 'only if all items are checked out and the record has at least one hold already' if not already set. Keep this tab open. 4. In another tab, open the OPAC. 5. Search the OPAC for a record with one item which is NOT checked out. 6. Go to place a hold on this record. Confirm you see a message saying that you will be charged a hold fee, even though not all items are checked out and the record does not have a hold --> This is the bug. 7. Apply patch and restart services. Items available, no holds placed 8. Repeat steps 5-6. This time, you should NOT see the hold fee message. Items available, holds placed 9. In your staff interface tab, find the same record. 10. Place a hold for a different patron on this record. 11. In your OPAC tab, find this record again and go to place a hold. You should NOT see the hold fee message. No items available, no holds placed 12. In your staff interface tab, cancel the hold placed on this record. 13. Check out the item to a different patron. 14. In your OPAC tab, find this record again and go to place a hold. You should NOT see the hold fee message. No items available, holds placed 15. In your staff interface tab, keep the item checked out to another patron. 16. Place a hold for a third patron on this record. 17. In your OPAC tab, find this record again and go to place a hold. You SHOULD see the hold fee message. Multiple holds 18. Search the OPAC for a record. Make sure your search will return more than one result, including our test record. 19. Check the checkbox for our test record, plus another record where the item is not checked out. 20. Click the Place hold button to place holds on all of our selected records. You should only see the hold fee message above our test record. 21. In your staff interface tab, test setting HoldFeeMode to the other values and confirm the hold message shows on the OPAC as expected. 22. Confirm tests pass t/db_dependent/Reserves/GetReserveFee.t Sponsored-by: Horowhenua Libraries Trust -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the| |This patch ensures release notes| |HoldFeeMode is considered | |when displaying a message | |to patrons on the OPAC that | |says they'll be charged a | |hold fee when placing or | |collecting the hold. | | | |When | |HoldFeeMode is set to | |not_always or "only if all | |items are checked out and | |the record has at least one | |hold already" then the hold | |fee message should only | |show if all items on the | |record are checked out, AND | |the record has at least one | |hold already - both of | |these conditions must be | |met. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs Signoff |Signed Off -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 David Nind <david@davidnind.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #142585|0 |1 is obsolete| | --- Comment #2 from David Nind <david@davidnind.com> --- Created attachment 142592 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=142592&action=edit Bug 31963: Only show hold fee msg on OPAC if patron will be charged This patch ensures HoldFeeMode is considered when displaying a message to patrons on the OPAC that says they'll be charged a hold fee when placing or collecting the hold. When HoldFeeMode is set to not_always or "only if all items are checked out and the record has at least one hold already" then the hold fee message should only show if all items on the record are checked out, AND the record has at least one hold already - both of these conditions must be met. To test: 1. Go to Administration -> Patron categories 2. Edit your patron category and give a hold fee of $1. 3. Go to Administration -> System preferences and search for HoldFeeMode. Set to 'only if all items are checked out and the record has at least one hold already' if not already set. Keep this tab open. 4. In another tab, open the OPAC. 5. Search the OPAC for a record with one item which is NOT checked out. 6. Go to place a hold on this record. Confirm you see a message saying that you will be charged a hold fee, even though not all items are checked out and the record does not have a hold --> This is the bug. 7. Apply patch and restart services. Items available, no holds placed 8. Repeat steps 5-6. This time, you should NOT see the hold fee message. Items available, holds placed 9. In your staff interface tab, find the same record. 10. Place a hold for a different patron on this record. 11. In your OPAC tab, find this record again and go to place a hold. You should NOT see the hold fee message. No items available, no holds placed 12. In your staff interface tab, cancel the hold placed on this record. 13. Check out the item to a different patron. 14. In your OPAC tab, find this record again and go to place a hold. You should NOT see the hold fee message. No items available, holds placed 15. In your staff interface tab, keep the item checked out to another patron. 16. Place a hold for a third patron on this record. 17. In your OPAC tab, find this record again and go to place a hold. You SHOULD see the hold fee message. Multiple holds 18. Search the OPAC for a record. Make sure your search will return more than one result, including our test record. 19. Check the checkbox for our test record, plus another record where the item is not checked out. 20. Click the Place hold button to place holds on all of our selected records. You should only see the hold fee message above our test record. 21. In your staff interface tab, test setting HoldFeeMode to the other values and confirm the hold message shows on the OPAC as expected. 22. Confirm tests pass t/db_dependent/Reserves/GetReserveFee.t Sponsored-by: Horowhenua Libraries Trust Signed-off-by: David Nind <david@davidnind.com> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Only show reserve fee |Only show hold fee message |message on OPAC if they |on OPAC if they will |will actually be charged |actually be charged -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- QA Contact|testopia@bugs.koha-communit |katrin.fischer@bsz-bw.de |y.org | -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Signed Off |Passed QA -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Attachment #142592|0 |1 is obsolete| | --- Comment #3 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- Created attachment 142985 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=142985&action=edit Bug 31963: Only show hold fee msg on OPAC if patron will be charged This patch ensures HoldFeeMode is considered when displaying a message to patrons on the OPAC that says they'll be charged a hold fee when placing or collecting the hold. When HoldFeeMode is set to not_always or "only if all items are checked out and the record has at least one hold already" then the hold fee message should only show if all items on the record are checked out, AND the record has at least one hold already - both of these conditions must be met. To test: 1. Go to Administration -> Patron categories 2. Edit your patron category and give a hold fee of $1. 3. Go to Administration -> System preferences and search for HoldFeeMode. Set to 'only if all items are checked out and the record has at least one hold already' if not already set. Keep this tab open. 4. In another tab, open the OPAC. 5. Search the OPAC for a record with one item which is NOT checked out. 6. Go to place a hold on this record. Confirm you see a message saying that you will be charged a hold fee, even though not all items are checked out and the record does not have a hold --> This is the bug. 7. Apply patch and restart services. Items available, no holds placed 8. Repeat steps 5-6. This time, you should NOT see the hold fee message. Items available, holds placed 9. In your staff interface tab, find the same record. 10. Place a hold for a different patron on this record. 11. In your OPAC tab, find this record again and go to place a hold. You should NOT see the hold fee message. No items available, no holds placed 12. In your staff interface tab, cancel the hold placed on this record. 13. Check out the item to a different patron. 14. In your OPAC tab, find this record again and go to place a hold. You should NOT see the hold fee message. No items available, holds placed 15. In your staff interface tab, keep the item checked out to another patron. 16. Place a hold for a third patron on this record. 17. In your OPAC tab, find this record again and go to place a hold. You SHOULD see the hold fee message. Multiple holds 18. Search the OPAC for a record. Make sure your search will return more than one result, including our test record. 19. Check the checkbox for our test record, plus another record where the item is not checked out. 20. Click the Place hold button to place holds on all of our selected records. You should only see the hold fee message above our test record. 21. In your staff interface tab, test setting HoldFeeMode to the other values and confirm the hold message shows on the OPAC as expected. 22. Confirm tests pass t/db_dependent/Reserves/GetReserveFee.t Sponsored-by: Horowhenua Libraries Trust Signed-off-by: David Nind <david@davidnind.com> Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Katrin Fischer <katrin.fischer@bsz-bw.de> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords| |release-notes-needed --- Comment #4 from Katrin Fischer <katrin.fischer@bsz-bw.de> --- It took me a bit to wrap my head around this. I believe while this advertises as a display fix, it's also a behavior change: GetReserveFee: - if( $notissued ) { + if( $notissued == 0 ) { + # all items are issued And later this is also used to determine what is charged: AddReserve: # add a reserve fee if needed if ( C4::Context->preference('HoldFeeMode') ne 'any_time_is_collected' ) { my $reserve_fee = GetReserveFee( $borrowernumber, $biblionumber ); ChargeReserveFee( $borrowernumber, $reserve_fee, $title ); } The system preference states: "Charge a hold fee only if all items are checked out and the record has at least one hold already". So the change in behaviour makes this happen. Only problem: I am having a hard time to phrase out the actual difference in when a user is charged right now :( Can you please update the bug description/title and release notes to be more clear about this not only affecting display please? -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Text to go in the|This patch ensures |When HoldFeeMode is set to release notes|HoldFeeMode is considered |not_always or "only if all |when displaying a message |items are checked out and |to patrons on the OPAC that |the record has at least one |says they'll be charged a |hold already", Koha will |hold fee when placing or |unexpectedly show a hold |collecting the hold. |fee message and charge a | |hold fee if at least one of |When |those conditions are met. |HoldFeeMode is set to | |not_always or "only if all |This patch fixes the |items are checked out and |behaviour so that a hold |the record has at least one |fee message is only shown, |hold already" then the hold |and hold fee only charged, |fee message should only |if all items on the record |show if all items on the |are checked out, AND the |record are checked out, AND |record has at least one |the record has at least one |hold already - both of |hold already - both of |these conditions must be |these conditions must be |met, as the system |met. |preference implies. Summary|Only show hold fee message |Only show hold fee message |on OPAC if they will |on OPAC and charge hold fee |actually be charged |is HoldFeeMode conditions | |are true as described in | |the system preference -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 --- Comment #5 from Aleisha Amohia <aleisha@catalyst.net.nz> --- (In reply to Katrin Fischer from comment #4)
Can you please update the bug description/title and release notes to be more clear about this not only affecting display please?
I've done an update, hopefully that's better -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Summary|Only show hold fee message |Only show hold fee message |on OPAC and charge hold fee |on OPAC and charge hold fee |is HoldFeeMode conditions |if HoldFeeMode conditions |are true as described in |are true as described in |the system preference |the system preference -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Tomás Cohen Arazi <tomascohen@gmail.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Version(s)| |22.11.00 released in| | Status|Passed QA |Pushed to master -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 --- Comment #6 from Tomás Cohen Arazi <tomascohen@gmail.com> --- Pushed to master for 22.11. Nice work everyone, thanks! -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Aleisha Amohia <aleisha@catalyst.net.nz> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |32142 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32142 [Bug 32142] Add HoldFeeMode option "if all items are checked out OR the record has at least one hold already" -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |lucas@bywatersolutions.com Status|Pushed to master |Needs documenting -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Needs documenting |RESOLVED CC| |caroline.cyr-la-rose@inlibr | |o.com Resolution|--- |FIXED --- Comment #7 from Caroline Cyr La Rose <caroline.cyr-la-rose@inlibro.com> --- This seems like a bug fix, nothing to add to the manual. Closing, but feel free to reopen with details if needed. -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Lucas Gass <lucas@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Blocks| |33210 Referenced Bugs: https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=33210 [Bug 33210] (Bug 31963 follow-up) No hold fee message on OPAC should be displayed when there is no fee -- You are receiving this mail because: You are watching all bug changes.
https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=31963 Lisette Scheer <lisette@bywatersolutions.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Keywords|release-notes-needed | -- You are receiving this mail because: You are watching all bug changes.
participants (1)
-
bugzilla-daemon@bugs.koha-community.org