summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorIvan Kohler <ivan@freeside.biz>2015-07-21 15:16:21 -0700
committerIvan Kohler <ivan@freeside.biz>2015-07-21 15:16:21 -0700
commit49c58715c06a5150805fd3019a72dc1bc6361514 (patch)
tree02261a6ec4c74d96204c492e51b429543029da72
parent71d389e6554fd9994ac9c18bc59fd43449b8cca1 (diff)
parent9f382a36db24e3782e5fdcbaf1a43b61659ffa4e (diff)
Merge branch 'master' of git.freeside.biz:/home/git/freeside
-rw-r--r--httemplate/search/cust_bill_pkg.cgi6
1 files changed, 3 insertions, 3 deletions
diff --git a/httemplate/search/cust_bill_pkg.cgi b/httemplate/search/cust_bill_pkg.cgi
index 6c2cfde1b..82e87fba9 100644
--- a/httemplate/search/cust_bill_pkg.cgi
+++ b/httemplate/search/cust_bill_pkg.cgi
@@ -240,7 +240,7 @@ if ( $conf->exists('enable_taxclasses') ) {
}
# used in several places
-my $itemdesc = 'COALESCE(part_fee.itemdesc, part_pkg.pkg, cust_bill_pkg.itemdesc)';
+my $itemdesc = 'COALESCE(cust_bill_pkg.itemdesc, part_fee.itemdesc, part_pkg.pkg, cust_bill_pkg.itemdesc)';
# valid in both the tax and non-tax cases
my $join_cust =
@@ -315,14 +315,14 @@ if ( $use_override ) {
$part_pkg = 'override';
}
push @select, "$part_pkg.pkgpart", "$part_pkg.pkg";
+push @select, "($itemdesc) AS itemdesc"; # available in all report modes
+
push @select, "COALESCE($part_pkg.taxclass, part_fee.taxclass) AS taxclass"
if $conf->exists('enable_taxclasses');
# the non-tax case
if ( $cgi->param('nottax') ) {
- push @select, "($itemdesc) AS itemdesc";
-
push @where,
'(cust_bill_pkg.pkgnum > 0 OR cust_bill_pkg.feepart IS NOT NULL)';