projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
RT#28246: Add more details to Change History for Discounts [actually fixed the bug]
[freeside.git]
/
httemplate
/
elements
/
change_history_common.html
diff --git
a/httemplate/elements/change_history_common.html
b/httemplate/elements/change_history_common.html
index
c858ec1
..
2d2c4c0
100644
(file)
--- a/
httemplate/elements/change_history_common.html
+++ b/
httemplate/elements/change_history_common.html
@@
-191,9
+191,10
@@
my %h_table_labelsub = (
my $discounts = {};
my $discount_descripsub = sub {
my($item) = @_;
my $discounts = {};
my $discount_descripsub = sub {
my($item) = @_;
- die "Could not find part_pkg for pkgpart " . $item->pkgpart
- unless $item->part_pkg;
- $pkgpart{$item->pkgpart} ||= $item->part_pkg->pkg;
+ $pkgpart{$item->pkgpart} ||= qsearchs({
+ 'table' => 'part_pkg',
+ 'hashref' => {'pkgpart' => $item->pkgpart}
+ })->pkg;
my $dnum = $item->discountnum;
$discounts->{$dnum} ||= qsearchs({
'table'=>'discount',
my $dnum = $item->discountnum;
$discounts->{$dnum} ||= qsearchs({
'table'=>'discount',