Bug 23319 - Reloading page when adding to basket from existing order can cause internal server error
Summary: Reloading page when adding to basket from existing order can cause internal s...
Status: Pushed to oldstable
Alias: None
Product: Koha
Classification: Unclassified
Component: Acquisitions (show other bugs)
Version: master
Hardware: All All
: P5 - low normal (vote)
Assignee: Nick Clemens
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2019-07-15 17:51 UTC by Nick Clemens
Modified: 2019-09-17 19:44 UTC (History)
5 users (show)

See Also:
Change sponsored?: ---
Patch complexity: Small patch
Who signed the patch off:
Text to go in the release notes:
Version(s) released in:
19.11.00,19.05.04


Attachments
Implement blocking errors for neworderbiblio and basket.pl (4.76 KB, patch)
2019-07-15 17:52 UTC, Nick Clemens
Details | Diff | Splinter Review
Implement blocking errors for neworderbiblio and basket.pl (4.79 KB, patch)
2019-07-19 21:10 UTC, Maryse Simard
Details | Diff | Splinter Review
Bug 23319: Implement blocking errors for neworderbiblio and basket.pl (4.89 KB, patch)
2019-08-10 11:56 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 Nick Clemens 2019-07-15 17:51:51 UTC
To recreate:
1 - Have a basket in acquisitions
2 - Add to basket from an existing record
3 - Perform a search with results
4 - Note the URL has no params
5 - Refresh the page
6 - Get an error
Comment 1 Nick Clemens 2019-07-15 17:52:22 UTC
Created attachment 91538 [details] [review]
Implement blocking errors for neworderbiblio and basket.pl

To test:
1 - Hit neworderbiblio with a query and no vendor
    http://localhost:8081/cgi-bin/koha/acqui/neworderbiblio.pl?q=cat
    Or, add to basket from existing record with a search
    Refresh the page (url has no parameters)
2 - Get an internal server error
3 - Add bookseller
    http://localhost:8081/cgi-bin/koha/acqui/neworderbiblio.pl?q=cat&booksellerid=1
4 - Click 'Order' on a result
5 - Internal server error
6 - Apply patch
7 - Repeat 1-4, you get 'Vendor not found' or 'Basket not found'
Comment 2 Maryse Simard 2019-07-19 21:10:10 UTC
Created attachment 91675 [details] [review]
Implement blocking errors for neworderbiblio and basket.pl

To test:
1 - Hit neworderbiblio with a query and no vendor
    http://localhost:8081/cgi-bin/koha/acqui/neworderbiblio.pl?q=cat
    Or, add to basket from existing record with a search
    Refresh the page (url has no parameters)
2 - Get an internal server error
3 - Add bookseller
    http://localhost:8081/cgi-bin/koha/acqui/neworderbiblio.pl?q=cat&booksellerid=1
4 - Click 'Order' on a result
5 - Internal server error
6 - Apply patch
7 - Repeat 1-4, you get 'Vendor not found' or 'Basket not found'

https://bugs.koha-community.org/show_bug.cgi?id=23319
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>
Comment 3 Katrin Fischer 2019-08-10 11:47:49 UTC
Don't forget the bug number in your commit messages!
Comment 4 Katrin Fischer 2019-08-10 11:56:57 UTC
Created attachment 92126 [details] [review]
Bug 23319: Implement blocking errors for neworderbiblio and basket.pl

To test:
1 - Hit neworderbiblio with a query and no vendor
    http://localhost:8081/cgi-bin/koha/acqui/neworderbiblio.pl?q=cat
    Or, add to basket from existing record with a search
    Refresh the page (url has no parameters)
2 - Get an internal server error
3 - Add bookseller
    http://localhost:8081/cgi-bin/koha/acqui/neworderbiblio.pl?q=cat&booksellerid=1
4 - Click 'Order' on a result
5 - Internal server error
6 - Apply patch
7 - Repeat 1-4, you get 'Vendor not found' or 'Basket not found'

https://bugs.koha-community.org/show_bug.cgi?id=23319
Signed-off-by: Maryse Simard <maryse.simard@inlibro.com>

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 5 Martin Renvoize 2019-08-13 10:33:38 UTC
Nice work!

Pushed to master for 19.11.00
Comment 6 Fridolin SOMERS 2019-09-02 12:19:28 UTC
Pushed to 19.05.x for 19.05.04
Comment 7 Lucas Gass 2019-09-17 19:44:37 UTC
backported to 18.11.x for 18.11.10