[Koha-bugs] [Bug 35310] Current renewals 'view' link doesnt work if renewals correspond to an item no longer checked out

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Nov 17 11:27:40 CET 2023


https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=35310

--- Comment #19 from Pedro Amorim <pedro.amorim at ptfs-europe.com> ---
Talked to Katrin about this. She is right. I made the 4th patch obsolete.
The message "X out of Y renewals have been logged" refers to the fact that a
checkout may have a renewals_count > 0 in the issues tables but not have a
corresponding entry in checkout_renewals.
This will happen for renewals that happened prior to bug 30275, and the reason
behind this is because the data to be moved on to the new checkout_renewals
table didn't exist and inserting fake data wouldn't make sense either.

The above was the background I was missing.

To reproduce the issue she mentions (with all patches applied - including the
(QA follow-up): Remove obsolete code patch), clean k-t-d:
1) Checkout barcode 39999000003154 for patron of cardnumber=42
2) Renew it through the database (emulating how the database worked prior to
bug 30275), run query:
update issues set renewals_count = 3 where issue_id = 1;
3) Visit /cgi-bin/koha/members/readingrec.pl?cardnumber=42
4) Notice "number of renewals" is 3. Click on "View", notice the modal is
empty.
5) Remove the last patch, however you want, suggestions:
git reset --hard <hash_of_previous_commit>
git revert <hash_of_commit_to_remove>
6) Restart plack, repeat 3) Notice it now says "Note: 0 out of 3 renewals have
been logged" as expected.

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list