[Koha-bugs] [Bug 13415] Prevent librarians from scanning multiple items into a single barcode field

bugzilla-daemon at bugs.koha-community.org bugzilla-daemon at bugs.koha-community.org
Fri Dec 12 14:04:34 CET 2014


http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13415

--- Comment #6 from Kyle M Hall <kyle at bywatersolutions.com> ---
I agree, I think I was a bit too aggressive. There is really no need to prevent
a barcode from being scanned before the page loads completely. I'll also change
the bind to on, as you are correct about that as well.

(In reply to Owen Leonard from comment #5)
> -    [% IF NEEDSCONFIRMATION %]
>             <input type="text" name="barcode" id="barcode" class="barcode
> focus" size="14" disabled="disabled" />
> -    [% ELSE %]
> -       <input type="text" name="barcode" id="barcode" class="barcode focus"
> size="14" />
> -    [% END %]
> 
> This change means that all circulation transactions must wait until
> document.ready() fires. Is this what we want? 
> 
> +    $('#mainform').bind('submit',function() {
> +        $('#barcode').on('keypress',function(event) {
> 
> Is there a reason to use bind() on #mainform instead of on()? "As of jQuery
> 1.7, the .on() method is the preferred method for attaching event handlers
> to a document." https://api.jquery.com/bind/

-- 
You are receiving this mail because:
You are watching all bug changes.


More information about the Koha-bugs mailing list