Bug 33789 - Checkout information is missing when adding a credit
Summary: Checkout information is missing when adding a credit
Status: Needs documenting
Alias: None
Product: Koha
Classification: Unclassified
Component: Fines and fees (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Lucas Gass
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-05-19 22:02 UTC by Lucas Gass
Modified: 2023-06-12 10:14 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Trivial patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00,23.05.01


Attachments
Bug 33789: Return issue info. when adding a credit (1.71 KB, patch)
2023-05-19 22:10 UTC, Lucas Gass
Details | Diff | Splinter Review
Bug 33789: Return issue info. when adding a credit (1.78 KB, patch)
2023-05-22 13:18 UTC, ByWater Sandboxes
Details | Diff | Splinter Review
Bug 33789: Add unit test (1.70 KB, patch)
2023-05-24 18:39 UTC, Lucas Gass
Details | Diff | Splinter Review
Bug 33789: Return issue info. when adding a credit (1.85 KB, patch)
2023-06-01 07:36 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 33789: Add unit test (1.79 KB, patch)
2023-06-01 07:36 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 33789: Update POD (1007 bytes, patch)
2023-06-05 18:19 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Lucas Gass 2023-05-19 22:02:32 UTC
add_credit does not pass any issue information when the credit is related to an issue. It would be handy if it did. 

To recreate:
1. Make sure MarkLostItemsAsReturned is set so a lost item will stay on a patrons account after being marked as lost.
2. Check an item out to a patron, make sure it has a replacementprice
3. Mark the item as lost.
4. Now check the item in. 
5. Go to the patrons account -> transaction tab. You should see 2 accountlines related to the item.
6. For the account type 'Lost item' you will see issue infomation ( check out date, due date, checkouted out from, etc )
7. For the account type 'Lost item fee refund' there is no issue information. 

It would be helpful for librarians if they could see this information in both places.
Comment 1 Lucas Gass 2023-05-19 22:10:34 UTC
Created attachment 151498 [details] [review]
Bug 33789: Return issue info. when adding a credit

To test:
1. Make sure MarkLostItemsAsReturned is set so a lost item will stay on a patrons account after being marked as lost.
2. Check an item out to a patron, make sure it has a replacementprice
3. Mark the item as lost.
4. Now check the item in.
5. Go to the patrons account -> transaction tab. You should see 2 accountlines related to the item.
6. For the account type 'Lost item' you will see issue infomation ( check out date, due date, checkouted out from, etc )
7. For the account type 'Lost item fee refund' there is no issue information.
8. Apply patch
9. Try 2 - 6 again. This time the 'Lost item fee refund' should include issue information.
Comment 2 ByWater Sandboxes 2023-05-22 13:18:47 UTC
Created attachment 151528 [details] [review]
Bug 33789: Return issue info. when adding a credit

To test:
1. Make sure MarkLostItemsAsReturned is set so a lost item will stay on a patrons account after being marked as lost.
2. Check an item out to a patron, make sure it has a replacementprice
3. Mark the item as lost.
4. Now check the item in.
5. Go to the patrons account -> transaction tab. You should see 2 accountlines related to the item.
6. For the account type 'Lost item' you will see issue infomation ( check out date, due date, checkouted out from, etc )
7. For the account type 'Lost item fee refund' there is no issue information.
8. Apply patch
9. Try 2 - 6 again. This time the 'Lost item fee refund' should include issue information.

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>
Comment 3 Jonathan Druart 2023-05-23 09:22:55 UTC
Please provide a test.
Comment 4 Lucas Gass 2023-05-24 18:39:22 UTC
Created attachment 151650 [details] [review]
Bug 33789: Add unit test
Comment 5 Jonathan Druart 2023-06-01 07:36:12 UTC
Created attachment 151897 [details] [review]
Bug 33789: Return issue info. when adding a credit

To test:
1. Make sure MarkLostItemsAsReturned is set so a lost item will stay on a patrons account after being marked as lost.
2. Check an item out to a patron, make sure it has a replacementprice
3. Mark the item as lost.
4. Now check the item in.
5. Go to the patrons account -> transaction tab. You should see 2 accountlines related to the item.
6. For the account type 'Lost item' you will see issue infomation ( check out date, due date, checkouted out from, etc )
7. For the account type 'Lost item fee refund' there is no issue information.
8. Apply patch
9. Try 2 - 6 again. This time the 'Lost item fee refund' should include issue information.

Signed-off-by: Laura Escamilla <laura.escamilla@bywatersolutions.com>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 6 Jonathan Druart 2023-06-01 07:36:14 UTC
Created attachment 151898 [details] [review]
Bug 33789: Add unit test

JD amended patch: Remove biblionumber => 144

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 7 Tomás Cohen Arazi 2023-06-05 18:19:26 UTC
Created attachment 152014 [details] [review]
Bug 33789: Update POD
Comment 8 Tomás Cohen Arazi 2023-06-05 18:37:36 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 9 Tomás Cohen Arazi 2023-06-09 14:08:05 UTC
Pushed to master for 23.05.

Nice work everyone, thanks!
Comment 10 Matt Blenkinsop 2023-06-12 10:14:14 UTC
Enhancement - not backporting to 22.11.x