Bug 34302 - Checkin and renewal error messages disappear immediately in checkouts table
Summary: Checkin and renewal error messages disappear immediately in checkouts table
Status: CLOSED FIXED
Alias: None
Product: Koha
Classification: Unclassified
Component: Circulation (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Jonathan Druart
QA Contact: Katrin Fischer
URL:
Keywords:
Depends on: 28653
Blocks:
  Show dependency treegraph
 
Reported: 2023-07-18 10:34 UTC by Julian Maurice
Modified: 2024-07-04 20:40 UTC (History)
6 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
23.11.00,23.05.04,22.11.11
Circulation function:


Attachments
Bug 34302: DO NOT PUSH - to test failure (629 bytes, patch)
2023-07-27 13:04 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 34302: (bug 28653 follow-up) Do not refresh the table if an error happened (2.45 KB, patch)
2023-07-27 13:04 UTC, Jonathan Druart
Details | Diff | Splinter Review
Bug 34302: (bug 28653 follow-up) Do not refresh the table if an error happened (2.50 KB, patch)
2023-09-06 02:58 UTC, David Cook
Details | Diff | Splinter Review
Bug 34302: (bug 28653 follow-up) Do not refresh the table if an error happened (2.56 KB, patch)
2023-09-19 19:38 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 Julian Maurice 2023-07-18 10:34:35 UTC
Since bug 28653, the checkouts table is automatically refreshed after checkin/renew. This prevents seeing error messages that are normally put inside this table.

Steps to reproduce:
1. Apply the patch on bug 27249
2. Follow the test plan in bug 27249 comment 3
3. See that the table is automatically refreshed. You should see a message replace the checkbox for a few milliseconds, and then the message will be replaced by a checkbox.
Comment 1 Katrin Fischer 2023-07-18 21:43:42 UTC
Thx for filing, Julian. I noticed the other day, it also prevents the success messages for reneals and checkins from being visible to the user.
Comment 2 Jonathan Druart 2023-07-27 13:04:04 UTC
Created attachment 153969 [details] [review]
Bug 34302: DO NOT PUSH - to test failure

Really, do not push! :D
Comment 3 Jonathan Druart 2023-07-27 13:04:06 UTC
Created attachment 153970 [details] [review]
Bug 34302: (bug 28653 follow-up) Do not refresh the table if an error happened

If checkin or renew failed, we should not refresh the table or it will
hide the error message.

Test plan:
Apply the DO NOT PUSH patch
Do a renew
=> No error in the table
Apply this patch
Do a renew
=> You see the error
Revert the DO NOT PUSH patch
Do a renew
=> The table is refreshed
Comment 4 David Cook 2023-09-06 02:58:42 UTC
Created attachment 155251 [details] [review]
Bug 34302: (bug 28653 follow-up) Do not refresh the table if an error happened

If checkin or renew failed, we should not refresh the table or it will
hide the error message.

Test plan:
Apply the DO NOT PUSH patch
Do a renew
=> No error in the table
Apply this patch
Do a renew
=> You see the error
Revert the DO NOT PUSH patch
Do a renew
=> The table is refreshed

Signed-off-by: David Cook <dcook@prosentient.com.au>
Comment 5 Victor Grousset/tuxayo 2023-09-09 19:44:57 UTC
Weird, I don't get the error.

I also tried with "Always show checkouts automatically" ticked and I don't see the difference when doing renewals with just the "the DO NOT PUSH patch" and both patches. Services have been restarted after patch applications.

Should the error be in the checkout list?
I only get the yellow message about confirming renewal on the top of the page.
Comment 6 Katrin Fischer 2023-09-19 19:38:54 UTC
Created attachment 155910 [details] [review]
Bug 34302: (bug 28653 follow-up) Do not refresh the table if an error happened

If checkin or renew failed, we should not refresh the table or it will
hide the error message.

Test plan:
Apply the DO NOT PUSH patch
Do a renew
=> No error in the table
Apply this patch
Do a renew
=> You see the error
Revert the DO NOT PUSH patch
Do a renew
=> The table is refreshed

Signed-off-by: David Cook <dcook@prosentient.com.au>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 7 Katrin Fischer 2023-09-19 19:40:29 UTC
I believe this might only be a partial fix. We have still lost the success messages.
Comment 8 Jonathan Druart 2023-09-20 07:08:32 UTC
(In reply to Katrin Fischer from comment #7)
> I believe this might only be a partial fix. We have still lost the success
> messages.

This is much more complicated...
Comment 9 Tomás Cohen Arazi (tcohen) 2023-09-22 15:39:18 UTC
Pushed to master for 23.11.

Nice work everyone, thanks!
Comment 10 Fridolin Somers 2023-09-22 20:35:03 UTC
Pushed to 23.05.x for 23.05.04
Comment 11 Jacob O'Mara 2023-10-17 11:45:10 UTC
Nice work everyone!

Pushed to oldstable for 22.11.x