Bug 41065: (bug 26553 follow-up) Remove JS error when submitting the form

Uncaught TypeError: patron_table.$ is not a function

Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
This commit is contained in:
Jonathan Druart 2025-10-22 08:55:04 +02:00 committed by Lucas Gass
parent e057c02ca3
commit ea123185b9
No known key found for this signature in database
GPG Key ID: 60B447398B0D36CA
1 changed files with 1 additions and 1 deletions

View File

@ -569,7 +569,7 @@
$('form[name="f"]').on("submit", function(){
// Add the checkboxes to the DOM before we submit the form
var form = this;
var checkboxes = patron_table.$('input:checkbox:checked').serializeArray();
var checkboxes = $(patron_table).find('input:checkbox:checked').serializeArray();
$.each(checkboxes, function(){
let borrowernumber = this.value;
if(!$(form).find('input[name="borrowernumber"][value="'+borrowernumber+'"]').length){