LP1309131 - Fix series link
authorKathy Lussier <klussier@masslnc.org>
Tue, 12 Aug 2014 21:33:16 +0000 (17:33 -0400)
committerBen Shum <bshum@biblio.org>
Thu, 18 Sep 2014 20:37:39 +0000 (16:37 -0400)
Clicking on a series link with a hyphen failed because the hyphen was
stripped and the two words are joined together. This branch changes
series.tts to replace special characters with a space, which is similar to
the links we build for authors.

Signed-off-by: Kathy Lussier <klussier@masslnc.org>
Signed-off-by: Ben Shum <bshum@biblio.org>
Open-ILS/src/templates/opac/parts/record/series.tt2

index 9518232..0ddc378 100644 (file)
@@ -20,7 +20,7 @@ BLOCK render_series;
                 NEXT UNLESS code.match('[a-z]');
                 # at this point, we actually have a partial term to use.
                 single_term = subfield.textContent | html;
-                all_terms.push(subfield.textContent.replace('[#"^$\+\-,\.:;&|\[\]()]', ''));
+                all_terms.push(subfield.textContent.replace('[#"^$\+\-,\.:;&|\[\]()]', ' '));
                 total_term = all_terms.join(" ").replace('\s+$', '');
 
                 url = mkurl(ctx.opac_root _ '/results',