Upload a valid CSV file to QOD results in error message. Uploads limited to csv. Incorrect filetype: application/vnd.sun.xml.calc Tested with a valid sample file from Bug 15684 - Fix encoding issues with quote upload https://bugs.koha-community.org/bugzilla3/attachment.cgi?id=47405
I've tried my own CSV file and those on Bug 15684 and I get no errors.
(In reply to Owen Leonard from comment #1) > I've tried my own CSV file and those on Bug 15684 and I get no errors. I think the issue is related to the fact that on my computer .csv files are associated with LibreOffice (Calc): application/vnd.sun.xml.calc See koha-tmpl/intranet-tmpl/prog/en/modules/tools/quotes-upload.tt line 241: if (!fileType.match(/comma-separated-values|csv|excel/i)) { alert(_("Uploads limited to csv. Incorrect filetype: %s").format(fileType));
Created attachment 51892 [details] [review] Bug 16589 - Quote of the day: Fix upload with csv files associated to LibreOffice Calc To reproduce: - Install LibreOffice and make sure that csv files are associated to Calc (Note: tested with Firefox 46.0.1 on Windows 8) - Go to Home > Tools > Quote editor > Quote uploader - Try to upload a valid CSV (e.g. Example from Bug 15684) Result: File can not be uploaded (Incorrect filetype: application/vnd.sun.xml.calc) To test: - Apply patch - Try to upload again Expected result: Quotes are imported.
Created attachment 51894 [details] [review] Bug 16589 - Quote of the day: Fix upload with csv files associated to LibreOffice Calc To reproduce: - Install LibreOffice and make sure that csv files are associated to Calc (Note: tested with Firefox 46.0.1 on Windows 8) - Go to Home > Tools > Quote editor > Quote uploader - Try to upload a valid CSV (e.g. Example from Bug 15684) Result: File can not be uploaded (Incorrect filetype: application/vnd.sun.xml.calc) To test: - Apply patch - Try to upload again Expected result: Quotes are imported. Signed-off-by: Frédéric Demians <f.demians@tamil.fr> Can't reproduce on a Mac but get it fails on a Windows Box: fixed with this patch.
Looks good but I cannot recreate the issue.
Created attachment 52244 [details] [review] Bug 16589 - Quote of the day: Fix upload with csv files associated to LibreOffice Calc To reproduce: - Install LibreOffice and make sure that csv files are associated to Calc (Note: tested with Firefox 46.0.1 on Windows 8) - Go to Home > Tools > Quote editor > Quote uploader - Try to upload a valid CSV (e.g. Example from Bug 15684) Result: File can not be uploaded (Incorrect filetype: application/vnd.sun.xml.calc) To test: - Apply patch - Try to upload again Expected result: Quotes are imported. Signed-off-by: Frédéric Demians <f.demians@tamil.fr> Can't reproduce on a Mac but get it fails on a Windows Box: fixed with this patch. Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org> Can't recreate on debian but the fix looks safe.
Pushed to master for Koha 16.11, thanks Marc!
Pushed in 16.05. Will be in 16.05.01.
Patch pushed to 3.22.x, will be in 3.22.8
Created attachment 53129 [details] [review] Bug 16859: Fix wrong item field name in export.pl Field callnumber should be itemcallnumber. For completeness, prefixing the joined fields with items table prefix. Note: You should expect Tools/Export to export only the items within a given itemcallnumber range, but if the biblio has one item in that range, the biblionumber is selected for export with ALL items. The script is designed that way (first select biblio numbers based on criteria, and run export with those biblio numbers). Test plan: [1] Select a biblio N with one item with say itemcallnumber X. [2] Goto Tools/Export. Select biblio range N,N and no itemcallnumber range. The biblio should be exported. [3] Select biblio range N,N and itemcallnumber range A,B. No output. [4] Select biblio range N,N and itemcallnumber range A,<empty>. Output. [5] Select biblio range N,N and itemcallnumber range <empty>,X. Output.
Comment on attachment 53129 [details] [review] Bug 16859: Fix wrong item field name in export.pl Sorry, wrong bug number..