Bugzilla – Attachment 108822 Details for
Bug 26172
Add a cashup summary view (with option to print)
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 26172: (follow-up) Add print option
Bug-26172-follow-up-Add-print-option.patch (text/plain), 3.63 KB, created by
Martin Renvoize (ashimema)
on 2020-08-21 13:46:00 UTC
(
hide
)
Description:
Bug 26172: (follow-up) Add print option
Filename:
MIME Type:
Creator:
Martin Renvoize (ashimema)
Created:
2020-08-21 13:46:00 UTC
Size:
3.63 KB
patch
obsolete
>From a2e66ea04f81155c9df95afc153235a8f7ad8c57 Mon Sep 17 00:00:00 2001 >From: Martin Renvoize <martin.renvoize@ptfs-europe.com> >Date: Fri, 21 Aug 2020 14:45:28 +0100 >Subject: [PATCH] Bug 26172: (follow-up) Add print option > >--- > .../prog/css/src/staff-global.scss | 33 +++++++++++++++++++ > .../prog/en/modules/pos/register.tt | 19 ++++++++++- > 2 files changed, 51 insertions(+), 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss b/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss >index e339309288..d1a9541f55 100644 >--- a/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss >+++ b/koha-tmpl/intranet-tmpl/prog/css/src/staff-global.scss >@@ -4469,3 +4469,36 @@ div .suggestion_note { > border-bottom-right-radius: 5px; > } > } >+ >+@media print { >+ body.modalprinter * { >+ visibility: hidden; >+ } >+ >+ body.modalprinter .modal-dialog.focused { >+ position: absolute; >+ padding: 0; >+ margin: 0; >+ left: 0; >+ top: 0; >+ } >+ >+ body.modalprinter .modal-dialog.focused .modal-content { >+ border-width: 0; >+ } >+ >+ body.modalprinter .modal-dialog.focused .modal-content .modal-header .modal-title, >+ body.modalprinter .modal-dialog.focused .modal-content .modal-body, >+ body.modalprinter .modal-dialog.focused .modal-content .modal-body * { >+ visibility: visible; >+ } >+ >+ body.modalprinter .modal-dialog.focused .modal-content .modal-header, >+ body.modalprinter .modal-dialog.focused .modal-content .modal-body { >+ padding: 0; >+ } >+ >+ body.modalprinter .modal-dialog.focused .modal-content .modal-header .modal-title { >+ margin-bottom: 20px; >+ } >+} >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt >index 319043cc2b..6dbf9c03af 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/pos/register.tt >@@ -294,7 +294,7 @@ > > <!-- Cashup summary modal --> > [% IF register.last_cashup %] >- <div class="modal" id="cashupSummaryModal" tabindex="-1" role="dialog" aria-labelledby="cashupSummaryLabel"> >+ <div class="modal printable" id="cashupSummaryModal" tabindex="-1" role="dialog" aria-labelledby="cashupSummaryLabel"> > <div class="modal-dialog" role="document"> > <div class="modal-content"> > <div class="modal-header"> >@@ -344,6 +344,7 @@ > </div> <!-- /.modal-body --> > <div class="modal-footer"> > <button type="button" class="btn btn-default" data-dismiss="modal">Close</button> >+ <button type="button" class="printModal btn btn-primary"><i class="fa fa-print"></i> Print</button> > </div> <!-- /.modal-footer --> > </div> <!-- /.modal-content --> > </div> <!-- /.modal-dialog --> >@@ -415,6 +416,22 @@ > win.focus(); > }); > >+ $('.modal.printable').on('shown.bs.modal', function() { >+ $('.modal-dialog', this).addClass('focused'); >+ $('body').addClass('modalprinter'); >+ >+ if ($(this).hasClass('autoprint')) { >+ window.print(); >+ } >+ }).on('hidden.bs.modal', function () { >+ $('.modal-dialog', this).removeClass('focused'); >+ $('body').removeClass('modalprinter'); >+ }); >+ >+ $('.printModal').click(function() { >+ window.print(); >+ }); >+ > $(document).ready(function() { > // http://jqueryui.com/demos/datepicker/#date-range > var dates = $( "#from, #to" ).datepicker({ >-- >2.20.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 26172
:
108093
|
108095
|
108523
|
108817
|
108818
|
108822
|
108825
|
108826
|
108827
|
111162
|
111163
|
111164
|
111598
|
111599
|
111600
|
111601
|
111629
|
111630
|
111631
|
111632
|
111633
|
111634
|
111668
|
111683
|
111691
|
111692
|
111731
|
111732
|
112907
|
112908
|
112909