Bug 38190

Summary: JS error on suggestion page
Product: Koha Reporter: Jonathan Druart <jonathan.druart>
Component: Staff interfaceAssignee: Jonathan Druart <jonathan.druart>
Status: RESOLVED FIXED QA Contact: Lucas Gass (lukeg) <lucas>
Severity: major    
Priority: P5 - low CC: gmcharlt, lucas, martin.renvoize
Version: unspecified   
Hardware: All   
OS: All   
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
24.11.00
Circulation function:
Bug Depends on: 34608    
Bug Blocks: 38191    
Attachments: Bug 38190: Remove JS error on suggestion page
Bug 38190: Remove JS error on suggestion page
Bug 38190: Remove JS error on suggestion page

Description Jonathan Druart 2024-10-17 09:11:02 UTC
Uncaught SyntaxError: redeclaration of const av_bsort1
Comment 1 Jonathan Druart 2024-10-17 09:12:30 UTC
Created attachment 172846 [details] [review]
Bug 38190: Remove JS error on suggestion page

This code could appear several time as we include it in modals

Test plan:
Go on http://localhost:8081/cgi-bin/koha/suggestion/suggestion.pl
Open the console
Notice that without this patch you see a JS error
  Uncaught SyntaxError: redeclaration of const av_bsort1
With this patch applied the error is gone.
Comment 2 David Nind 2024-10-17 09:44:33 UTC
Created attachment 172848 [details] [review]
Bug 38190: Remove JS error on suggestion page

This code could appear several time as we include it in modals

Test plan:
Go on http://localhost:8081/cgi-bin/koha/suggestion/suggestion.pl
Open the console
Notice that without this patch you see a JS error
  Uncaught SyntaxError: redeclaration of const av_bsort1
With this patch applied the error is gone.

Signed-off-by: David Nind <david@davidnind.com>
Comment 3 Owen Leonard 2024-10-17 11:16:33 UTC
*** Bug 38182 has been marked as a duplicate of this bug. ***
Comment 4 Lucas Gass (lukeg) 2024-10-17 18:23:51 UTC
Created attachment 172925 [details] [review]
Bug 38190: Remove JS error on suggestion page

This code could appear several time as we include it in modals

Test plan:
Go on http://localhost:8081/cgi-bin/koha/suggestion/suggestion.pl
Open the console
Notice that without this patch you see a JS error
  Uncaught SyntaxError: redeclaration of const av_bsort1
With this patch applied the error is gone.

Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Lucas Gass <lucas@bywatersolutions.com>
Comment 5 Katrin Fischer 2024-10-18 12:27:54 UTC
Pushed for 24.11!

Well done everyone, thank you!
Comment 6 Lucas Gass (lukeg) 2024-11-19 16:00:28 UTC
Missing 24.05.x deps