Bugzilla – Attachment 10427 Details for
Bug 7563
Silent print slips using Firefox PlugIn jsPrintSetup and new staff client preference
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[REBASED] Bug 8272 - OPAC : date expiration format
REBASED-Bug-8272---OPAC--date-expiration-format.patch (text/plain), 6.16 KB, created by
Marc Véron
on 2012-06-22 10:11:04 UTC
(
hide
)
Description:
[REBASED] Bug 8272 - OPAC : date expiration format
Filename:
MIME Type:
Creator:
Marc Véron
Created:
2012-06-22 10:11:04 UTC
Size:
6.16 KB
patch
obsolete
>From c56bc1557ee7c1d1a6ff38f3f77e37cd8fccc8ad Mon Sep 17 00:00:00 2001 >From: Owen Leonard <oleonard@myacpl.org> >Date: Tue, 19 Jun 2012 13:08:28 -0400 >Subject: [PATCH] [REBASED] Bug 8272 - OPAC : date expiration format >Content-Type: text/plain; charset="utf-8" > >Adding TT date filter to output of expiration date >on OPAC user page. > >Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz> >Signed-off-by: Delaye Stephane <stephane.delaye@biblibre.com> >Signed-off-by: Paul Poulain <paul.poulain@biblibre.com> > >http://bugs.koha-community.org/show_bug.cgi?id=7563 >--- > installer/data/mysql/sysprefs.sql | 1 + > installer/data/mysql/updatedatabase.pl | 7 +++++++ > .../en/modules/admin/preferences/staff_client.pref | 5 +++++ > .../prog/en/modules/circ/printslip.tt | 12 ++++++++---- > koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt | 2 +- > members/printslip.pl | 2 ++ > 6 files changed, 24 insertions(+), 5 deletions(-) > >diff --git a/installer/data/mysql/sysprefs.sql b/installer/data/mysql/sysprefs.sql >index 6c6d91b..9900de9 100644 >--- a/installer/data/mysql/sysprefs.sql >+++ b/installer/data/mysql/sysprefs.sql >@@ -371,3 +371,4 @@ INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES(' > INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('SuspendHoldsOpac', '1', NULL , 'Allow holds to be suspended from the OPAC.', 'YesNo'); > INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('DefaultLanguageField008','','Fill in the default language for field 008 Range 35-37 (e.g. eng, nor, ger, see <a href="http://www.loc.gov/marc/languages/language_code.html">MARC Code List for Languages</a>)','','Free'); > INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('OPACShowBarcode','0','Show items barcode in holding tab','','YesNo'); >+INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('IntranetSlipPrinterJS','','Use this JavaScript for printing slips. Define at least function printThenClose(). For use e.g. with Firefox PlugIn jsPrintSetup, see http://jsprintsetup.mozdev.org/','','Free'); >diff --git a/installer/data/mysql/updatedatabase.pl b/installer/data/mysql/updatedatabase.pl >index d06a188..650ca61 100755 >--- a/installer/data/mysql/updatedatabase.pl >+++ b/installer/data/mysql/updatedatabase.pl >@@ -5392,6 +5392,13 @@ if (C4::Context->preference("Version") < TransformToNum($DBversion)) { > SetVersion ($DBversion); > } > >+$DBversion ="XXX"; >+if ( C4::Context->preference("Version") < TransformToNum($DBversion) ) { >+ $dbh->do("INSERT INTO systempreferences (variable,value,explanation,options,type) VALUES('IntranetSlipPrinterJS','','Use this JavaScript for printing slips. Define at least function printThenClose(). For use e.g. with Firefox PlugIn jsPrintSetup, see http://jsprintsetup.mozdev.org/','','Free')"); >+ print "Upgrade to $DBversion done (Add system preference IntranetSlipPrinterJS))\n"; >+ SetVersion($DBversion); >+} >+ > =head1 FUNCTIONS > > =head2 TableExists($table) >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref >index b93f8fd..b6be289 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/admin/preferences/staff_client.pref >@@ -16,6 +16,11 @@ Staff Client: > class: url > - on all pages in the staff interface, instead of the default. (This should be a complete URL, starting with <code>http://</code>.) > - >+ - "Use the following JavaScript for printing slips. Define at least function printThenClose(). For use e.g. with Firefox PlugIn jsPrintSetup, see http://jsprintsetup.mozdev.org/:" >+ - pref: IntranetSlipPrinterJS >+ type: textarea >+ class: code >+ - > - "Include the following CSS on all pages in the staff client:" > - pref: IntranetUserCSS > type: textarea >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/printslip.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/printslip.tt >index 3e60d73..7b29d4e 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/circ/printslip.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/circ/printslip.tt >@@ -8,10 +8,14 @@ > [% END %] > > <script language="javascript"> >- function printThenClose() { >- window.print(); >- window.close(); >- } >+[% IF ( IntranetSlipPrinterJS ) %] >+ [% IntranetSlipPrinterJS %] >+[% ELSE %] >+ function printThenClose() { >+ window.print(); >+ window.close(); >+ } >+[% END %] > </script> > </head> > <body id="circ_printslip" class="circ" onload="printThenClose();"> >diff --git a/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt b/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt >index 0b8930f..8ae9a77 100644 >--- a/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt >+++ b/koha-tmpl/opac-tmpl/prog/en/modules/opac-user.tt >@@ -83,7 +83,7 @@ $.tablesorter.addParser({ > > [% IF ( BORROWER_INF.warndeparture ) %] > <div class="dialog alert" id="warndeparture"> >- <strong>Please note:</strong><span> Your card will expire on <span id="warndeparture_date">[% BORROWER_INF.warndeparture %]</span>. Please contact the library for more information.</span> >+ <strong>Please note:</strong><span> Your card will expire on <span id="warndeparture_date">[% BORROWER_INF.warndeparture | $KohaDates %]</span>. Please contact the library for more information.</span> > [% IF ( BORROWER_INF.returnbeforeexpiry ) %]<span id="warndeparture_returnbeforeexpiry"> Also note that you must return all checked out items before your card expires.</span>[% END %] > </div> > [% END %] >diff --git a/members/printslip.pl b/members/printslip.pl >index 3a499cd..71fdda2 100755 >--- a/members/printslip.pl >+++ b/members/printslip.pl >@@ -89,4 +89,6 @@ $template->param( > error => $error, > ); > >+$template->param( IntranetSlipPrinterJS => C4::Context->preference('IntranetSlipPrinterJS' ) ); >+ > output_html_with_http_headers $input, $cookie, $template->output; >-- >1.7.2.5
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 Raw
Actions:
View
Attachments on
bug 7563
:
9290
|
9306
|
9307
|
9981
|
10063
|
10068
|
10071
|
10073
|
10104
|
10427
|
10428
|
10557
|
10570
|
11149