Bugzilla – Attachment 171040 Details for
Bug 37836
Prevent submitting empty barcodes in self check-in
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 37836: Prevent submitting empty barcodes in Self check-in
Bug-37836-Prevent-submitting-empty-barcodes-in-Sel.patch (text/plain), 1.69 KB, created by
Biblibre Sandboxes
on 2024-09-04 23:34:16 UTC
(
hide
)
Description:
Bug 37836: Prevent submitting empty barcodes in Self check-in
Filename:
MIME Type:
Creator:
Biblibre Sandboxes
Created:
2024-09-04 23:34:16 UTC
Size:
1.69 KB
patch
obsolete
>From ea51d15ff6530312aa413522db366541221e783d Mon Sep 17 00:00:00 2001 >From: Bo Gustavsson <bosse@gustavsson.one> >Date: Wed, 4 Sep 2024 21:49:47 +0200 >Subject: [PATCH] Bug 37836: Prevent submitting empty barcodes in Self check-in > >This patch disbles the "Submit" button when the barcode field is empty. > >To test this patch: > >Add the patch to your koha clone >Enable the "SelfCheckInModule". >Open the page and the "Submit" button should be disabled when the barcode field is empty. > >Signed-off-by: Sam Sowanick <sam.sowanick@corvallisoregon.gov> >--- > .../bootstrap/en/modules/sci/sci-main.tt | 27 +++++++++++++++++++ > 1 file changed, 27 insertions(+) > >diff --git a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sci/sci-main.tt b/koha-tmpl/opac-tmpl/bootstrap/en/modules/sci/sci-main.tt >index bc5d1affeb..d10c3fb0b0 100644 >--- a/koha-tmpl/opac-tmpl/bootstrap/en/modules/sci/sci-main.tt >+++ b/koha-tmpl/opac-tmpl/bootstrap/en/modules/sci/sci-main.tt >@@ -281,6 +281,33 @@ > } > } > } >+ >+ >+ function checkBarcodeInput() { >+ var inputField = document.getElementById("barcode_input"); >+ var button = document.getElementById("sci_append_button"); >+ >+ if (inputField.value.trim() === "") { >+ button.disabled = true; >+ } else { >+ button.disabled = false; >+ } >+ } >+ >+checkBarcodeInput(); >+ >+document.getElementById("barcode_input").addEventListener("input", checkBarcodeInput); >+ >+document.getElementById("sci_append_button").addEventListener("click", function() { >+ setTimeout(checkBarcodeInput, 10); >+}); >+ >+ >+ >+ >+ >+ >+ > </script> > > [% IF ( Koha.Preference('SelfCheckInUserJS') ) %] >-- >2.39.2
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 37836
:
171038
|
171040
|
172936