Bug 23467

Summary: Duplicated screen if error in opac-reserve.pl
Product: Koha Reporter: David Roberts <david.roberts>
Component: OPACAssignee: Jonathan Druart <jonathan.druart>
Status: CLOSED FIXED QA Contact: Katrin Fischer <katrin.fischer>
Severity: major    
Priority: P5 - low CC: fridolin.somers, jonathan.druart, martin.renvoize
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:
19.11.00,19.05.05
Circulation function:
Bug Depends on: 22542    
Bug Blocks:    
Attachments: Screenshot of the duplicated screen
Screenshot of the duplicated screen
Bug 23467: Exit after output_html - opac-reserve.pl
Bug 23467: Exit after output_html - opac-reserve.pl

Description David Roberts 2019-08-15 23:28:37 UTC
Created attachment 92249 [details]
Screenshot of the duplicated screen

At 18.11, if the BlockExpiredPatronOpacActions system preference is set to block, when an expired patron attempts to place a hold in the OPAC, the screen duplicates with a cookies error in the middle of the screen. See screenshot attached. I can't reproduce this at 17.11. 

To reproduce at 18.11.

1) Ensure that BlockExpiredPatronOpacActions is set to Block, and ensure that this is not be overridden by the Patron Category policy. 
2) Log into the OPAC as an expired user.
3) Search for an item to hold
4) Click Place Hold

Setting the BlockExpiredPatronOpacActions system preference means the hold gets placed normally. I also notice that the lower half of the screen (i.e. the duplicated portion) ignores any jQuery configuration.
Comment 1 Katrin Fischer 2019-08-16 06:08:02 UTC
Confirmed on master too.
Comment 2 Owen Leonard 2019-08-16 12:31:23 UTC
Created attachment 92271 [details]
Screenshot of the duplicated screen

Re-posting the screenshot as a JPEG
Comment 3 Katrin Fischer 2019-11-03 22:37:52 UTC
OPAC bug, major... giving it another nudge.
Comment 4 Jonathan Druart 2019-11-06 10:01:13 UTC
Created attachment 95093 [details] [review]
Bug 23467: Exit after output_html - opac-reserve.pl

To avoid double screen

There are several ways to recreate the issue, the easiest is:
  /cgi-bin/koha/opac-reserve.pl?biblionumber=

You should see "ERROR: No record id specified."
Comment 5 Katrin Fischer 2019-11-06 11:02:43 UTC
Created attachment 95097 [details] [review]
Bug 23467: Exit after output_html - opac-reserve.pl

To avoid double screen

There are several ways to recreate the issue, the easiest is:
  /cgi-bin/koha/opac-reserve.pl?biblionumber=

You should see "ERROR: No record id specified."

Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Comment 6 Katrin Fischer 2019-11-06 11:09:18 UTC
Nudging it further. I tested both, the way Jonathan suggested with the missing parameter and the original problem case with the holds.
Comment 7 Martin Renvoize (ashimema) 2019-11-06 17:10:18 UTC
Nice work!

Pushed to master for 19.11.00
Comment 8 Fridolin Somers 2019-11-15 10:05:00 UTC
Pushed to 19.05.x for 19.05.05