Bug 33929 - Cannot export genre/form authority framework
Summary: Cannot export genre/form authority framework
Status: Failed QA
Alias: None
Product: Koha
Classification: Unclassified
Component: System Administration (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal
Assignee: Bugs List
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-06-06 18:26 UTC by Alejo Janin
Modified: 2024-05-09 18:04 UTC (History)
3 users (show)

See Also:
Change sponsored?: ---
Patch complexity: ---
Documentation contact:
Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:


Attachments
Console error screenshot (32.50 KB, image/jpeg)
2023-06-06 18:26 UTC, Alejo Janin
Details
Bug 33929: Resolved issue with "Export"/"Import" button click error (13.48 KB, patch)
2023-07-12 14:05 UTC, Peter Vashchuk
Details | Diff | Splinter Review
Bug 33929: Resolved issue with "Export"/"Import" button click error (13.52 KB, patch)
2023-07-12 15:05 UTC, Sam Lau
Details | Diff | Splinter Review

Note You need to log in before you can comment on or make changes to this bug.
Description Alejo Janin 2023-06-06 18:26:55 UTC
Created attachment 152064 [details]
Console error screenshot

Hi,

There is an error when clicking the "Export" button of the genre/form authority framework (it also happens with the "Import" button).

I'm attaching a screenshot with the web console message.

I'm using version 22.11.06


Thanks,
Alejo
Comment 1 Katrin Fischer 2023-06-08 22:22:14 UTC
Confirmed in master as well.
Comment 2 Peter Vashchuk 2023-07-12 14:05:36 UTC
Created attachment 153365 [details] [review]
Bug 33929: Resolved issue with "Export"/"Import" button click error

This patch addresses an error that occurred when clicking the "Export" button within the genre/form authority framework (the same issue was observed with the "Import" button). The error message displayed in the console was as follows:
"Uncaught Error: Syntax error, unrecognized expression: #exportModal_GENRE/FFORM4"

The error was caused by special symbols, particularly the  "/" in the code of the auth type. To fix this, the patch is using a plugin designed to handle character filtering for HTML IDs,  "$HtmlId", instead of "html" that kept "/" in "GENRE/FFORM4" which was causing this problem.
Comment 3 Sam Lau 2023-07-12 15:05:25 UTC
Created attachment 153369 [details] [review]
Bug 33929: Resolved issue with "Export"/"Import" button click error

This patch addresses an error that occurred when clicking the "Export" button within the genre/form authority framework (the same issue was observed with the "Import" button). The error message displayed in the console was as follows:
"Uncaught Error: Syntax error, unrecognized expression: #exportModal_GENRE/FFORM4"

The error was caused by special symbols, particularly the  "/" in the code of the auth type. To fix this, the patch is using a plugin designed to handle character filtering for HTML IDs,  "$HtmlId", instead of "html" that kept "/" in "GENRE/FFORM4" which was causing this problem.

Signed-off-by: Sam Lau <samalau@gmail.com>
Comment 4 Katrin Fischer 2023-07-12 21:24:30 UTC
There is no error now, but the file is incomplete. Only the header and some 2 more lines with #-# in the CSV export (7 lines total). 
Other frameworks export fine.

Please include a test plan in your commit message.
Comment 5 Caroline Cyr La Rose 2024-01-09 22:18:47 UTC
Still valid on master
Comment 6 Esther Melander 2024-05-09 18:04:57 UTC
Would it be simpler, and maybe faster, to rename the Genre Authority type without the special character? Is there a reason it needs to have it?