X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fcust_bill_pkg.pm;h=b6e852897ab59e464c7d35efc83ce4b2f510f8b1;hb=07560581aedba753147fcb3f6a5e7c30bdc2f77f;hp=abf021845109a416082e8ba43f29404c8d67c17b;hpb=87a986f35b347affed5f1e1ff5c5c7c59ccd4ad1;p=freeside.git diff --git a/FS/FS/cust_bill_pkg.pm b/FS/FS/cust_bill_pkg.pm index abf021845..b6e852897 100644 --- a/FS/FS/cust_bill_pkg.pm +++ b/FS/FS/cust_bill_pkg.pm @@ -119,6 +119,7 @@ sub insert { 'detail' => (ref($detail) ? $detail->[1] : $detail ), 'amount' => (ref($detail) ? $detail->[2] : '' ), 'classnum' => (ref($detail) ? $detail->[3] : '' ), + 'phonenum' => (ref($detail) ? $detail->[4] : '' ), }; $error = $cust_bill_pkg_detail->insert; if ( $error ) { @@ -299,6 +300,7 @@ Returns the previous cust_bill_pkg for this package, if any. sub previous_cust_bill_pkg { my $self = shift; + return unless $self->sdate; qsearchs({ 'table' => 'cust_bill_pkg', 'hashref' => { 'pkgnum' => $self->pkgnum, @@ -370,7 +372,7 @@ sub details { $format_sub = $opt{format_function} if $opt{format_function}; map { ( $_->format eq 'C' - ? &{$format_sub}( $_->detail ) + ? &{$format_sub}( $_->detail, $_ ) : &{$escape_function}( $_->detail ) ) }