Bug 11049 - Multiple URLs (possibly truncated) presented as one URL in opac-sendbasket email message
Summary: Multiple URLs (possibly truncated) presented as one URL in opac-sendbasket em...
Status: RESOLVED DUPLICATE of bug 14614
Alias: None
Product: Koha
Classification: Unclassified
Component: OPAC (show other bugs)
Version: Main
Hardware: All All
: P5 - low normal (vote)
Assignee: Owen Leonard
QA Contact: Testopia
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-10-14 11:36 UTC by Marcel de Rooy
Modified: 2015-07-29 11:40 UTC (History)
2 users (show)

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


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Marcel de Rooy 2013-10-14 11:36:42 UTC
I stumbled over this in 3.8. A record contains four longer URLs (in MARC 856) that in total exceed the field length of biblioitems.url (255 chars).
In saving this info into biblioitems.url the output of TransformMarcToKoha is truncated.
When you put this biblio in the opac cart and send the cart, this truncated field is inserted into a html template. After that it should be sent as a plain text email. Somewhere in this process the truncated field causes the email output to be mangled. Information after the URLs like item info and the closing line with dashes do no longer appear.

It seems like this bug could be reproduced in master (looking at the code and templates). But unfortunately, in master when sending the basket another error pops up before the form of opac-sendbasket is shown.
Can't call method "field" on an undefined value at /usr/share/koha/testclone/C4/Biblio.pm line 1713.
This is in the routine GetMarcNotes and it is actually not really related to the error presented in this report ;)
Comment 1 Marcel de Rooy 2013-10-14 12:49:43 UTC
OK. The error on GetMarcNotes was completely off-scope. But the new template for opac-sendbasket seems to resolve this error on master.
So it looks like an old problem (3.8).
Marking it as solved.
Comment 2 Marcel de Rooy 2013-10-14 13:10:50 UTC
Just a final note: Copying the new template to 3.8 and taking over the change in opac-sendbasket to use encode_qp on body and email_header will 'resolve' the problem under 3.8 too.

But not completely by the way :)
Note that the message is now complete again, but the URL (remember it were actually four urls) is now presented in the email as one big URL. (And it is still truncated.)
Comment 3 Marcel de Rooy 2013-10-14 13:21:31 UTC
So, we can actually reopen this bug for master now. But we need to rephrase it.

If you have multiple URLs in a biblio record with tag 856. They are put into one biblioitem field (possibly truncated to 255 chars) and presented as one url in the opac sendbasket email message.
Two errors at one time.
Comment 4 Katrin Fischer 2015-07-29 11:40:27 UTC

*** This bug has been marked as a duplicate of bug 14614 ***