]> git.koha-community.org Git - koha.git/commit
Bug 9507: prevent submit: refactor some code in a js file
authorJonathan Druart <jonathan.druart@biblibre.com>
Wed, 30 Jan 2013 14:19:58 +0000 (15:19 +0100)
committerTomas Cohen Arazi <tomascohen@gmail.com>
Mon, 3 Jun 2013 13:40:01 +0000 (10:40 -0300)
commitc8ea6ba025455a26a585733fdb214942a9823a45
treed2930a480edaf8ffeb39af613aed4c2d352fcf5f
parentd22fb794dcc977c096665c4aa44ffc2185af7d46
Bug 9507: prevent submit: refactor some code in a js file

This patch refactors some code in a js file.

Test plan:
On acqui/neworderempty.pl, acqui/orderreceive.pl and
serials/serials-edit.tt try to scan a barcode (or press enter) on the
form and check that it is not sent.

Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Have to note that the code for IE9 does not work. Before and after this patch.
If we refactor code, it would have been nice to resolve this too.
But I do not oppose pushing this patch.
The test uses 'an ancient Netscape property' window.Event (uppercase!) to make
the distinction between browers and event models. Some more documentation here
would be welcome too.

Signed-off-by: Galen Charlton <gmc@esilibrary.com>
(cherry picked from commit 9e4c289d3f68aaab5d47172940e30fba0819804e)

Signed-off-by: Tomas Cohen Arazi <tomascohen@gmail.com>
Refactoring, but needed for 10310 inclusion
koha-tmpl/intranet-tmpl/prog/en/js/prevent_submit.js [new file with mode: 0644]
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/neworderempty.tt
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/orderreceive.tt
koha-tmpl/intranet-tmpl/prog/en/modules/serials/serials-edit.tt