From d77b69f1bdf85945fefb9b6952cbd815118c0154 Mon Sep 17 00:00:00 2001 From: Jonathan Prykop Date: Thu, 19 Feb 2015 15:34:47 -0600 Subject: [PATCH] RT#28246: Add more details to Change History for Discounts [actually fixed the bug] --- httemplate/elements/change_history_common.html | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/httemplate/elements/change_history_common.html b/httemplate/elements/change_history_common.html index 9fc85aa53..2d2c4c0be 100644 --- a/httemplate/elements/change_history_common.html +++ b/httemplate/elements/change_history_common.html @@ -191,7 +191,10 @@ my %h_table_labelsub = ( my $discounts = {}; my $discount_descripsub = sub { my($item) = @_; - $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', -- 2.20.1