summaryrefslogtreecommitdiff
path: root/httemplate/search/cust_bill.html
diff options
context:
space:
mode:
authorivan <ivan>2005-03-06 03:04:29 +0000
committerivan <ivan>2005-03-06 03:04:29 +0000
commit34647c32b50ce3b8ee1b6d3d7aef4ba9d0297bdb (patch)
treefaf2226212cf421ffc5d7c998f9eab9ed2ef9216 /httemplate/search/cust_bill.html
parentf34557b8890dcc63db6c5588233dc7bfa9d39f22 (diff)
add Excel and CSV download of templated reports and clean up their HTML formatting, closes; Bug#520, Bug#1107
Diffstat (limited to 'httemplate/search/cust_bill.html')
-rwxr-xr-xhttemplate/search/cust_bill.html79
1 files changed, 39 insertions, 40 deletions
diff --git a/httemplate/search/cust_bill.html b/httemplate/search/cust_bill.html
index 3ae624af2..440e468e3 100755
--- a/httemplate/search/cust_bill.html
+++ b/httemplate/search/cust_bill.html
@@ -58,44 +58,43 @@
: '';
};
-%>
-<%= include( 'elements/search.html',
- 'title' => 'Invoice Search Results',
- 'name' => 'invoices',
- 'query' => $sql_query,
- 'count_query' => $count_query,
- 'count_addl' => [ '$%.2f total invoiced',
- '$%.2f total outstanding balance',
- ],
- 'redirect' => $link,
- 'header' =>
- [ 'Invoice #', qw(Balance Amount Date), 'Contact name',
- 'Company' ],
- 'fields' => [
- 'invnum',
- sub { sprintf('$%.2f', shift->get('owed') ) },
- sub { sprintf('$%.2f', shift->charged ) },
- sub { time2str('%b %d %Y', shift->_date ) },
- sub { my $cust_bill = shift;
- my $cust_main = $cust_bill->cust_main;
- $cust_main
- ? $cust_main->get('last'). ', '. $cust_main->first
- : "WARNING: can't find cust_main.custnum ".
- $cust_bill->custnum. ' (cust_bill.invnum '.
- $cust_bill->invnum. ')';
- },
- sub { my $cust_main = shift->cust_main;
- $cust_main ? $cust_main->company : '';
- },
- ],
- 'links' => [
- $link,
- $link,
- $link,
- $link,
- $clink,
- $clink,
- ],
-
- )
+%><%= include( 'elements/search.html',
+ 'title' => 'Invoice Search Results',
+ 'name' => 'invoices',
+ 'query' => $sql_query,
+ 'count_query' => $count_query,
+ 'count_addl' => [ '$%.2f total invoiced',
+ '$%.2f total outstanding balance',
+ ],
+ 'redirect' => $link,
+ 'header' =>
+ [ 'Invoice #', qw(Balance Amount Date), 'Contact name',
+ 'Company' ],
+ 'fields' => [
+ 'invnum',
+ sub { sprintf('$%.2f', shift->get('owed') ) },
+ sub { sprintf('$%.2f', shift->charged ) },
+ sub { time2str('%b %d %Y', shift->_date ) },
+ sub { my $cust_bill = shift;
+ my $cust_main = $cust_bill->cust_main;
+ $cust_main
+ ? $cust_main->get('last'). ', '. $cust_main->first
+ : "WARNING: can't find cust_main.custnum ".
+ $cust_bill->custnum. ' (cust_bill.invnum '.
+ $cust_bill->invnum. ')';
+ },
+ sub { my $cust_main = shift->cust_main;
+ $cust_main ? $cust_main->company : '';
+ },
+ ],
+ 'links' => [
+ $link,
+ $link,
+ $link,
+ $link,
+ $clink,
+ $clink,
+ ],
+
+ )
%>