should fix wrapping of CDRs reported under IEq, RT#9964
authorivan <ivan>
Sun, 10 Oct 2010 23:41:32 +0000 (23:41 +0000)
committerivan <ivan>
Sun, 10 Oct 2010 23:41:32 +0000 (23:41 +0000)
FS/FS/cust_bill.pm

index d364ac5..d9c2c40 100644 (file)
@@ -2291,7 +2291,7 @@ sub print_generic {
   my $nbsp = $nbsps{$format};
 
   my %escape_functions = ( 'latex'    => \&_latex_escape,
-                           'html'     => \&encode_entities,
+                           'html'     => \&_html_escape, #\&encode_entities,
                            'template' => sub { shift },
                          );
   my $escape_function = $escape_functions{$format};
@@ -3165,6 +3165,14 @@ sub _latex_escape {
   $value;
 }
 
+
+sub _html_escape {
+  my $value = shift;
+  encode_entities($value);
+  $value =~ s/ +/&nbsp;/g;
+  $value;
+}
+
 #utility methods for print_*
 
 sub _translate_old_latex_format {