Bugzilla – Attachment 125320 Details for
Bug 28940
IntranetUserJS is called twice on spinelable-print.tt
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 28940: In spinelabel-print.tt call IntranetUserJS only once
Bug-28940-In-spinelabel-printtt-call-IntranetUserJ.patch (text/plain), 1.55 KB, created by
Katrin Fischer
on 2021-09-26 11:48:53 UTC
(
hide
)
Description:
Bug 28940: In spinelabel-print.tt call IntranetUserJS only once
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2021-09-26 11:48:53 UTC
Size:
1.55 KB
patch
obsolete
>From ebb4d13349e66a26084e1a4b0998257f8a5a249c Mon Sep 17 00:00:00 2001 >From: Lucas Gass <lucas@bywatersolutions.com> >Date: Wed, 1 Sep 2021 19:16:15 +0000 >Subject: [PATCH] Bug 28940: In spinelabel-print.tt call IntranetUserJS only > once > >1. In IntranetUser add some JS that will target spinelabel-print.tt, I used this: > if ( $('#labels_spinelabel-print').length ) { > $('#labels_spinelabel-print').append('<div>TEST</div>'); > console.log('TEST'); > } >2. Generate a quick spine label >3. Once you have entered a barcode the JS will go off 2x. With the jQuery added you will see 2 div's with the word 'TEST'. Look at the console and you will also see TEST console logged 2x. >4. Apply patch >5. Try seto 2 and 3 again, the JS should only be called once. > >Signed-off-by: Andrew Fuerste-Henry <andrew@bywatersolutions.com> > >Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de> >--- > koha-tmpl/intranet-tmpl/prog/en/modules/labels/spinelabel-print.tt | 1 - > 1 file changed, 1 deletion(-) > >diff --git a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/spinelabel-print.tt b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/spinelabel-print.tt >index d9505eac7d..43ee65ea64 100644 >--- a/koha-tmpl/intranet-tmpl/prog/en/modules/labels/spinelabel-print.tt >+++ b/koha-tmpl/intranet-tmpl/prog/en/modules/labels/spinelabel-print.tt >@@ -35,7 +35,6 @@ > [% INCLUDE 'slip-print.inc' #printThenClose %] > [% END %] > <script> >- [% IntranetUserJS | $raw %] > $(document).ready(function(){ > $(".print-label").on("click", function(e){ > e.preventDefault(); >-- >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 28940
:
124415
|
124843
| 125320