Bugzilla – Attachment 3891 Details for
Bug 6126
Slip print doesn't work on Webkit based browsers
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[tt] Wrap print;close in a function
0001-Bug-6126-tt-Slip-print-doesn-t-work-on-Webkit-based-.patch (text/plain), 2.97 KB, created by
Tomás Cohen Arazi (tcohen)
on 2011-04-12 11:02:22 UTC
(
hide
)
Description:
[tt] Wrap print;close in a function
Filename:
MIME Type:
Creator:
Tomás Cohen Arazi (tcohen)
Created:
2011-04-12 11:02:22 UTC
Size:
2.97 KB
patch
obsolete
>From 65cd1eb3ee5f5970aa3ffa31e9e823a10a6c8cc2 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@gmail.com> >Date: Tue, 12 Apr 2011 07:59:17 -0300 >Subject: [PATCH] [Bug 6126][tt] Slip print doesn't work on Webkit based browsers >Content-Type: text/plain; charset="utf-8" > >Wrap window.print();window.close(); with a function called when body has finished loading. Prevents webkit from closing before page is loaded and print dialog presented to the user. >--- > .../prog/en/modules/members/moremember-receipt.tt | 4 +++- > .../prog/en/modules/members/printfeercpt.tt | 4 +++- > .../prog/en/modules/members/printinvoice.tt | 4 +++- > 3 files changed, 9 insertions(+), 3 deletions(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tt >index aa76755..4a85ccb 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/moremember-receipt.tt >@@ -5,11 +5,13 @@ > <link rel="stylesheet" type="text/css" href="[% themelang %]/css/print.css" /> > > <script language="javascript"> >+ function printThenClose() { > window.print(); > window.close(); >+ } > </script> > </head> >-<body> >+<body onload="printThenClose();"> > > <div id="receipt"> > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/printfeercpt.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/printfeercpt.tt >index f1a661d..7625260 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/printfeercpt.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/printfeercpt.tt >@@ -4,11 +4,13 @@ > <link rel="shortcut icon" href="[% IF ( IntranetFavicon ) %][% IntranetFavicon %][% ELSE %][% themelang %]/includes/favicon.ico[% END %]" type="image/x-icon" /> > <link rel="stylesheet" type="text/css" href="[% themelang %]/css/printreceiptinvoice.css" /> > <script language="javascript"> >+ function printThenClose() { > window.print(); > window.close(); >+ } > </script> > </head> >-<body> >+<body onload="printThenClose();"> > > <div id="receipt"> > <!-- The table with the account items --> >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/members/printinvoice.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/members/printinvoice.tt >index d2933df..a712e83 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/members/printinvoice.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/members/printinvoice.tt >@@ -4,11 +4,13 @@ > <link rel="shortcut icon" href="[% IF ( IntranetFavicon ) %][% IntranetFavicon %][% ELSE %][% themelang %]/includes/favicon.ico[% END %]" type="image/x-icon" /> > <link rel="stylesheet" type="text/css" href="[% themelang %]/css/printreceiptinvoice.css" /> > <script language="javascript"> >+ function printThenClose() { > window.print(); > window.close(); >+ } > </script> > </head> >-<body> >+<body onload="printThenClose();"> > > <div id="receipt"> > <!-- The table with the account items --> >-- >1.7.1 >
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 6126
:
3817
|
3818
|
3890
|
3891
|
3896
|
3943