[freeside-commits] freeside/FS/FS cust_bill.pm,1.183,1.184

Ivan,,, ivan at wavetail.420.am
Tue Feb 12 21:15:36 PST 2008


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv16683

Modified Files:
	cust_bill.pm 
Log Message:
fix missing fill-in values on invoices resulting from skewed hash ($conf->config returning empty list in list context)

Index: cust_bill.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_bill.pm,v
retrieving revision 1.183
retrieving revision 1.184
diff -u -d -r1.183 -r1.184
--- cust_bill.pm	15 Dec 2007 01:45:22 -0000	1.183
+++ cust_bill.pm	13 Feb 2008 05:15:34 -0000	1.184
@@ -1843,7 +1843,7 @@
   }
 
   my %invoice_data = (
-    'company_name'    => $conf->config('company_name'),
+    'company_name'    => scalar( $conf->config('company_name') ),
     'company_address' => join("\n", $conf->config('company_address') ). "\n",
     'custnum'         => $self->custnum,
     'invnum'          => $self->invnum,
@@ -2244,7 +2244,7 @@
     or die 'While compiling ' . $templatefile . ': ' . $Text::Template::ERROR;
 
   my %invoice_data = (
-    'company_name'    => $conf->config('company_name'),
+    'company_name'    => scalar( $conf->config('company_name') ),
     'company_address' => join("\n", $conf->config('company_address') ). "\n",
     'custnum'         => $self->custnum,
     'invnum'          => $self->invnum,
@@ -2431,6 +2431,11 @@
     push @{$invoice_data{'total_items'}}, $total;
   }
 
+  warn "filling in HTML template for invoice ". $self->invnum. "\n"
+    if $DEBUG;
+  warn join("\n", map "  $_ => ".$invoice_data{$_}, keys %invoice_data ). "\n"
+    if $DEBUG > 1;
+
   $html_template->fill_in( HASH => \%invoice_data);
 }
 



More information about the freeside-commits mailing list