Summary: | Fix process of suggesting purchase of existing title for non-logged-in users | ||
---|---|---|---|
Product: | Koha | Reporter: | Owen Leonard <oleonard> |
Component: | OPAC | Assignee: | Jonathan Druart <jonathan.druart> |
Status: | CLOSED FIXED | QA Contact: | Marcel de Rooy <m.de.rooy> |
Severity: | normal | ||
Priority: | P5 - low | CC: | 1joynelson, jonathan.druart, m.de.rooy, testopia |
Version: | Main | ||
Hardware: | All | ||
OS: | All | ||
Change sponsored?: | --- | Patch complexity: | Small patch |
Documentation contact: | Documentation submission: | ||
Text to go in the release notes: | Version(s) released in: |
20.05.00
|
|
Circulation function: | |||
Bug Depends on: | 14963 | ||
Bug Blocks: | |||
Attachments: |
Bug 24345: Fix process of suggesting purchase of existing title for non-logged-in users
Bug 24345: Fix process of suggesting purchase of existing title for non-logged-in users Bug 24345: Fix OPACViewOthersSuggestions Bug 24345: Fix process of suggesting purchase of existing title for non-logged-in users Bug 24345: Fix OPACViewOthersSuggestions |
Description
Owen Leonard
2020-01-04 23:24:42 UTC
Created attachment 96829 [details] [review] Bug 24345: Fix process of suggesting purchase of existing title for non-logged-in users The 'op' parameter is removed from the CGI object ($input) before get_template_and_user is called. When the user is redirected to the login form (from checkauth, called from get_template_and_user), the op is lost. Moving down the deletion fixes the problem. Test plan: Logout at the OPAC Go the detail page of a bibliographic record Click the "Suggest for purchase" link Fill the login form => Without this patch you will see your suggestion list => With this patch applied the new suggestion form will be displayed, prefilled with the biblio's info Created attachment 96830 [details] [review] Bug 24345: Fix process of suggesting purchase of existing title for non-logged-in users The 'op' parameter is removed from the CGI object ($input) before get_template_and_user is called. When the user is redirected to the login form (from checkauth, called from get_template_and_user), the op is lost. Moving down the deletion fixes the problem. Test plan: Logout at the OPAC Go the detail page of a bibliographic record Click the "Suggest for purchase" link Fill the login form => Without this patch you will see your suggestion list => With this patch applied the new suggestion form will be displayed, prefilled with the biblio's info Signed-off-by: Owen Leonard <oleonard@myacpl.org> This change has side effects. It seems to break viewing other purchase suggestions anonymously (enable OPACViewOthersSuggestions). Might be possible that we only should add the op=else parameter in the masthead link, but it needs more checking. The script is a bit messy in the handling of $op.. Created attachment 97651 [details] [review] Bug 24345: Fix OPACViewOthersSuggestions Default value for $op needs to be set before the get_template_and_user lines as it's tested for OPACViewOthersSuggestions. (In reply to Marcel de Rooy from comment #3) > This change has side effects. > It seems to break viewing other purchase suggestions anonymously (enable > OPACViewOthersSuggestions). Might be possible that we only should add the > op=else parameter in the masthead link, but it needs more checking. > > The script is a bit messy in the handling of $op.. Ha! Thanks Marcel! Created attachment 97717 [details] [review] Bug 24345: Fix process of suggesting purchase of existing title for non-logged-in users The 'op' parameter is removed from the CGI object ($input) before get_template_and_user is called. When the user is redirected to the login form (from checkauth, called from get_template_and_user), the op is lost. Moving down the deletion fixes the problem. Test plan: Logout at the OPAC Go the detail page of a bibliographic record Click the "Suggest for purchase" link Fill the login form => Without this patch you will see your suggestion list => With this patch applied the new suggestion form will be displayed, prefilled with the biblio's info Signed-off-by: Owen Leonard <oleonard@myacpl.org> Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Created attachment 97718 [details] [review] Bug 24345: Fix OPACViewOthersSuggestions Default value for $op needs to be set before the get_template_and_user lines as it's tested for OPACViewOthersSuggestions. Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> Nice work everyone! Pushed to master for 20.05 Missing dependency, not backported to 19.11 |