Bug 14505

Summary: single quotes in journal number cause print routing list window to not appear
Product: Koha Reporter: Liz Rea <liz>
Component: SerialsAssignee: Joonas Kylmälä <joonas.kylmala>
Status: CLOSED FIXED QA Contact: Testopia <testopia>
Severity: normal    
Priority: P5 - low CC: colin.campbell, gwilliams, jonathan.druart, tomascohen, veron
Version: Main   
Hardware: All   
OS: All   
See Also: http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14691
http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=14744
Change sponsored?: --- Patch complexity: ---
Documentation contact: Documentation submission:
Text to go in the release notes:
Version(s) released in:
Circulation function:
Attachments: Bug 14505: single quotes in journal number cause print routing list window to not appear
[Signed-off] Bug 14505: single quotes in journal number cause print routing list window to not appear
Bug 14505: single quotes in journal number cause print routing list window to not appear

Description Liz Rea 2015-07-08 02:51:42 UTC
To replicate:

Have a serial, receive a serial with a number as follows:

iam 1000: The World's Leading Patent Professionals 2015 

Set up a routing list for this serial.

Click on "Serial Collection" 

[Fail condition] Click "Print routing list" - the window will not appear.

Edit the received serials, remove the single quote from the number, save it.

[Success condition] Click "Print routing list" - the window will appear, and the list can be printed.

There may be other characters that cause this as well.
Comment 1 Joonas Kylmälä 2015-08-20 09:35:58 UTC Comment hidden (obsolete)
Comment 2 Liz Rea 2015-08-20 21:14:49 UTC
I was looking at something similar for bug 14691 and David pointed out http://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=13618 which may fix this sort of problem across the board. I just haven't had a chance to investigate whether or not that is true.

Cheers,
Liz
Comment 3 Joonas Kylmälä 2015-08-21 07:18:55 UTC
If we use something like Template::Stash::AutoEscape then we can get this fixed quite soon but if we wait for the Template Toolkit version 2.26 in Debian then it might take a while. We will wait and see what happens.
Comment 4 Liz Rea 2015-08-23 21:09:32 UTC
It will fix it, but the patch for that isn't ready and may take a while - it would be good to get bugfixes like this at least back into stable versions.

Liz
Comment 5 Joonas Kylmälä 2015-08-24 05:05:04 UTC
(In reply to Liz Rea from comment #4)
> It will fix it, but the patch for that isn't ready and may take a while - it
> would be good to get bugfixes like this at least back into stable versions.
> 
> Liz

I'll then change the status to "needs sign off".
Comment 6 Marc Véron 2015-08-31 09:57:53 UTC Comment hidden (obsolete)
Comment 7 Jonathan Druart 2015-09-01 09:20:43 UTC
Created attachment 42140 [details] [review]
Bug 14505: single quotes in journal number cause print routing list window to not appear

Escapes single quotes from serial.serialseq string.

Test plan:

1. Have a serial with a number which has single quote in it.
2. Go to Serials -> Find some serial subscription -> Serial collection.
3. Set up a routing list for this serial.
4. Click on Print list under the column Routing.
5. Notice that the print window doesn't open.
6. Apply patch.
7. Notice that the print window opens.

Sponsored-by: Vaara-kirjastot

Followed test plan. Works as expected.
Signed-off-by: Marc Véron <veron@veron.ch>

Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Comment 8 Tomás Cohen Arazi (tcohen) 2015-09-25 14:58:56 UTC
Patch pushed to master.

Thanks Joonas!