Bug 29169 - Wrong "daily limit" warning when article request is not available
Summary: Wrong "daily limit" warning when article request is not available
Status: Pushed to master
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: unspecified
Hardware: All All
: P5 - low normal (vote)
Assignee: Tomás Cohen Arazi
QA Contact: Marcel de Rooy
URL:
Keywords:
Depends on: 27945
Blocks:
  Show dependency treegraph
 
Reported: 2021-10-05 09:19 UTC by Jonathan Druart
Modified: 2021-10-08 15:01 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: String patch
Text to go in the release notes:
Version(s) released in:
21.11.00


Attachments
Bug 29169: Fix wrong terminology when article request is not available (2.50 KB, patch)
2021-10-07 15:03 UTC, Tomás Cohen Arazi
Details | Diff | Splinter Review
Bug 29169: Fix wrong terminology when article request is not available (2.60 KB, patch)
2021-10-08 06:06 UTC, Marcel de Rooy
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Druart 2021-10-05 09:19:13 UTC
If you have reached the daily limit (bug 27945) and article request are not possible, the error will be "daily limit reached" when it should be "No article requests can be made for this record"

Step to recreate:
- Turn the syspref "ArticleRequests" on
- Circ rule "Article requests" => No
- "Default article requests limits" for your patron's category => 0

/cgi-bin/koha/opac-request-article.pl?biblionumber=1

=> "You reached your article requests daily limit."

The ELSIF ELSE in opac-request-article.tt need to be improved.
Comment 1 Tomás Cohen Arazi 2021-10-07 15:03:06 UTC
Created attachment 125893 [details] [review]
Bug 29169: Fix wrong terminology when article request is not available

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Comment 2 Marcel de Rooy 2021-10-08 06:03:30 UTC
+                        [% SWITCH error_message %]
+                            [% CASE 'article_request_limit_reached'       %]You reached your open article requests limit.
+                            [% CASE 'article_request_unhandled_exception' %]An error has occurred.
+                        [% END %]

No blocker, but there is no fallback.
Comment 3 Marcel de Rooy 2021-10-08 06:05:22 UTC
(In reply to Marcel de Rooy from comment #2)
> +                        [% SWITCH error_message %]
> +                            [% CASE 'article_request_limit_reached'      
> %]You reached your open article requests limit.
> +                            [% CASE 'article_request_unhandled_exception'
> %]An error has occurred.
> +                        [% END %]
> 
> No blocker, but there is no fallback.

Which there wasnt either ;)
Comment 4 Marcel de Rooy 2021-10-08 06:06:30 UTC
Created attachment 125919 [details] [review]
Bug 29169: Fix wrong terminology when article request is not available

Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Comment 5 Marcel de Rooy 2021-10-08 06:07:02 UTC
Trivial edit. SO + QA combined
Comment 6 Jonathan Druart 2021-10-08 15:01:28 UTC
Pushed to master for 21.11, thanks to everybody involved!