From 93810e2d18325d6f3b56cb3738d4400af69e6908 Mon Sep 17 00:00:00 2001 From: jeff Date: Mon, 19 May 2008 04:07:45 +0000 Subject: backport voip_cdr's upstream_simple, and the columnization features --- conf/invoice_html | 16 +++++++++------- conf/invoice_latex | 13 +++++++++---- 2 files changed, 18 insertions(+), 11 deletions(-) (limited to 'conf') diff --git a/conf/invoice_html b/conf/invoice_html index b13b08f46..ddede78ce 100644 --- a/conf/invoice_html +++ b/conf/invoice_html @@ -86,13 +86,15 @@ ''. $line->{'amount'}. ''. '' ; - foreach my $ext_desc ( @{$line->{'ext_description'} } ) { - $OUT .= - ''. - ''. - '- '. $ext_desc. ''. - ''. - '' + if ( @{$line->{'ext_description'} } ) { + $OUT .= ''; + foreach my $ext_desc ( @{$line->{'ext_description'} } ) { + $OUT .= + ''. + ''. + '' + } + $OUT .= '
- '. $ext_desc. '
'; } } diff --git a/conf/invoice_latex b/conf/invoice_latex index c63514568..ba66d6437 100644 --- a/conf/invoice_latex +++ b/conf/invoice_latex @@ -229,10 +229,15 @@ Terms: [@-- $terms --@]\\ $OUT .= '\FSdesc{' . $line->{'ref'} . '}{' . $line->{'description'} . '}' . '{' . $line->{'amount'} . "}${rowbreak}\n"; - foreach my $ext_desc (@$ext_description) { - $ext_desc = substr($ext_desc, 0, 80) . '...' - if (length($ext_desc) > 80); - $OUT .= '\FSextdesc{' . $ext_desc . '}' . "${rowbreak}\n"; + if (@$ext_description) { + $OUT .= '\multicolumn{1}{l}{\rule{0pt}{1.0ex}} &'; + $OUT .= '\multicolumn{2}{l}{\small{\begin{tabular}{llllll}';#cheating at 6 + foreach my $ext_desc (@$ext_description) { + $ext_desc = substr($ext_desc, 0, 80) . '...' + if (length($ext_desc) > 80); + $OUT .= "$ext_desc \\\\${rowbreak}\n"; + } + $OUT .="\\end{tabular}}}\\\\${rowbreak}\n"; } } -- cgit v1.2.1