Bugzilla – Attachment 96107 Details for
Bug 21565
SCO checkout confirm should be modal
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 21565: Turn SCO receipt promt into modal
Bug-21565-Turn-SCO-receipt-promt-into-modal.patch (text/plain), 3.21 KB, created by
Lucas Gass (lukeg)
on 2019-12-09 17:49:55 UTC
(
hide
)
Description:
Bug 21565: Turn SCO receipt promt into modal
Filename:
MIME Type:
Creator:
Lucas Gass (lukeg)
Created:
2019-12-09 17:49:55 UTC
Size:
3.21 KB
patch
obsolete
>From 98c10d6653219e5cf290dd6ace75884d38e1dfb1 Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Mon, 9 Dec 2019 17:48:25 +0000 >Subject: [PATCH] Bug 21565: Turn SCO receipt promt into modal > >--- > .../opac-tmpl/bootstrap/en/modules/sco/sco-main.tt | 36 +++++++++++++++++++--- > 1 file changed, 32 insertions(+), 4 deletions(-) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt >index e475470488..dcb18c97dd 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/sco/sco-main.tt >@@ -400,7 +400,27 @@ > </div> <!-- / .row-fluid --> > </div> <!-- / .container-fluid --> > </div> <!-- / .main --> >- <span id="audio-alert"></span> >+ >+ <div class="modal fade" tabindex="-1" role="dialog" id="printConfirm"> >+ <div class="modal-dialog" role="document"> >+ <div class="modal-content"> >+ <div class="modal-header"> >+ <h5 class="modal-title">Print Receipt</h5> >+ <button type="button" class="close" data-dismiss="modal" aria-label="Close"> >+ <span aria-hidden="true">×</span> >+ </button> >+ </div> >+ <div class="modal-body"> >+ <p>Would you like to print a recipt?</p> >+ </div> >+ <div class="modal-footer"> >+ <button type="button" class="btn btn-primary printConfirm">Yes</button> >+ <button type="button" class="btn btn-secondary printDeny" data-dismiss="modal">No</button> >+ </div> >+ </div> >+ </div> >+ </div> >+ <span id="audio-alert"></span> > > [% INCLUDE 'opac-bottom.inc' %] > [% BLOCK jsinclude %] >@@ -473,17 +493,25 @@ > ] > })); > >- $("#logout_form").submit(function(){ >+ $("#logout_form").submit(function(e){ >+ e.preventDefault(); > clearTimeout(mainTimeout); > [% IF Koha.Preference('SelfCheckReceiptPrompt') %] >+ $("#printConfirm").removeClass('fade'); > var confirmStart = Date.now(); >- if(confirm(_("Would you like to print a receipt?"))){ >+ $(".printConfirm").click( function() { > if ( (Date.now() - confirmStart) < [% SelfCheckTimeout | html %] ) { > window.open("/cgi-bin/koha/sco/printslip.pl?borrowernumber=[% borrowernumber | html %]&print=qslip"); >+ location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; > } else { > alert(_("Timeout while waiting for print confirmation")); > } >- } >+ }) >+ $(".printDeny").click( function() { >+ location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; >+ }) >+ [% ELSE %] >+ location.href = '/cgi-bin/koha/sco/sco-main.pl?op=logout'; > [% END %] > > return true; >-- >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 21565
:
96107
|
103703
|
103971
|
103972
|
103980
|
104188