projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
RT#71995: Cancel Packages [turned off debug in email_search]
[freeside.git]
/
FS
/
FS
/
part_pkg_taxproduct.pm
diff --git
a/FS/FS/part_pkg_taxproduct.pm
b/FS/FS/part_pkg_taxproduct.pm
index
c12a432
..
e86d028
100644
(file)
--- a/
FS/FS/part_pkg_taxproduct.pm
+++ b/
FS/FS/part_pkg_taxproduct.pm
@@
-153,7
+153,11
@@
sub part_pkg_taxrate {
map { $_->taxproductnum }
$self->expand_cch_taxproduct
);
map { $_->taxproductnum }
$self->expand_cch_taxproduct
);
- $extra_sql .= "AND taxproductnum IN($tpnums)";
+
+ # if there are no taxproductnums, there are no matching tax classes
+ return if length($tpnums) == 0;
+
+ $extra_sql .= " AND taxproductnum IN($tpnums)";
my $addl_from = 'LEFT JOIN part_pkg_taxproduct USING ( taxproductnum )';
my $order_by = 'ORDER BY taxclassnum, length(geocode) desc, length(taxproduct) desc';
my $addl_from = 'LEFT JOIN part_pkg_taxproduct USING ( taxproductnum )';
my $order_by = 'ORDER BY taxclassnum, length(geocode) desc, length(taxproduct) desc';