https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=43451 --- Comment #2 from Martin Renvoize (ashimema) <martin.renvoize@openfifth.co.uk> --- Created attachment 210034 --> https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=210034&action=edit Bug 43451: Show the receipt buttons when the automatic receipt window is blocked With FinePaymentAutoPopup on, members/boraccount.tt and members/pay.tt open the receipt with window.open() on page load, after paycollect.pl has redirected back to them. A window opened without a user action can be blocked by the browser, and then staff never see the receipt. A Bug 41705 style redirect cannot be used here: the landing page also shows the renewal results and refreshed balance, and the tab that submits the payment must stay on it. Instead, keep the automatic window, and when window.open() returns nothing, reveal the "Payment received" box from Bug 43402 with its Print and Email receipt buttons. Clicking one is a user action, so it cannot be blocked. When the window opens normally the page is unchanged. When FinePaymentAutoPopup is off the box is shown as before. members/paycollect.tt also calls window.open(), but paycollect.pl redirects after a payment, so that code does not run in practice and is left alone. To test: 1. Apply Bug 43402 and this patch. 2. Set FinePaymentAutoPopup to "Do" and give a patron a charge. 3. Take a payment from the patron's Accounting > Make a payment. => With popups allowed the receipt opens and prints, and the page shows no "Payment received" box (as before). 4. Block popups for the staff site in the browser and repeat. => The "Payment received" box is shown with the message "Your browser blocked the receipt window" and the Print receipt button, and Email receipt if the patron has an email address. => Pay a charge that causes a renewal: the renewal feedback and balance are still shown. 5. Set FinePaymentAutoPopup to "Don't" and repeat. => The "Payment received" box is shown without the blocked message. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> -- You are receiving this mail because: You are watching all bug changes.