Bugzilla – Attachment 114685 Details for
Bug 27282
Printing broken in some versions of Chrome
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 27282: Add window.onafterprint function
Bug-27282-Add-windowonafterprint-function.patch (text/plain), 1.42 KB, created by
Nick Clemens (kidclamp)
on 2020-12-23 16:02:30 UTC
(
hide
)
Description:
Bug 27282: Add window.onafterprint function
Filename:
MIME Type:
Creator:
Nick Clemens (kidclamp)
Created:
2020-12-23 16:02:30 UTC
Size:
1.42 KB
patch
obsolete
>From 671aea62837a498b3dabed161c0289ea431d5a2a Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Fri, 18 Dec 2020 17:28:54 +0000 >Subject: [PATCH] Bug 27282: Add window.onafterprint function > >TO TEST: >-set up a new list with a few items >-go to /cgi-bin/koha/virtualshelves/shelves.pl and view that list. >-Click 'Print List' in Chrome. >-The tab opens but immediately closes itself. >-Apply patch and clear cache >-Try again, the print dialouge remains open > >Signed-off-by: Owen Leonard <oleonard@myacpl.org> > >Signed-off-by: Nick Clemens <nick@bywatersolutions.com> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt | 5 ++++- > 1 file changed, 4 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >index 61d3b9bbe1..8db95e7950 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/virtualshelves/shelves.tt >@@ -434,7 +434,10 @@ > <script> > $( document ).ready(function() { > window.print(); >- setTimeout('window.close()', 1); >+ window.onafterprint = function () { >+ window.close(); >+ } >+ setTimeout('window.close()', 1000); // Hack for Chrome < 63 > }); > </script> > [% END %] >-- >2.11.0
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 27282
:
114535
|
114562
|
114685
|
114933
|
119338
|
119339
|
119752
|
119753