KMAIN-1510
authorMichael Glass <mglass@catalystitservices.com>
Thu, 19 Mar 2015 21:02:22 +0000 (17:02 -0400)
committerBill Erickson <berickxx@gmail.com>
Thu, 21 Mar 2019 19:46:23 +0000 (15:46 -0400)
Added regex to remove dashes from browse results display. Regex
was used vs. refactor of code causing dash due to time constraints on
modifing existing database functions

modified:   KCLS/openils/var/templates_kcls/opac/browse_results.tt2

Signed-off-by: Michael Glass <mglass@catalystitservices.com>
KCLS/openils/var/templates_kcls/opac/browse_results.tt2

index 650d10a..3fbaaa8 100644 (file)
                                                 }) %]" 
                                                 onclick = "new_tab( this )" 
                                                 >
-                                                [% result.value %]
+                                                [% result.value.replace(',\s--\s(\d+)', ', $1') %]
                                               </a>  
                                         [% ELSE %]
                                             <a href="[% mkurl(
                                                 ctx.opac_root _ '/browse_items', {
                                                     'fi:has_browse_entry' => (CGI.param('qtype') _ ',' _ result.browse_entry _ ',' _ result.fields)
                                                 }) %]">
-                                                [% result.value %]
+                                                [% result.value.replace(',\s--\s(\d+)', ', $1') %]
                                             </a>
                                         [% END %]