From fed4da7a88ca7255b4945589286fe6f8bc63cd79 Mon Sep 17 00:00:00 2001 From: Ivan Kohler Date: Wed, 26 Dec 2012 16:12:45 -0800 Subject: [PATCH] don't set %item_dates for custom invoice formats if package option disable_line_item_date_ranges is on, RT#19907 --- FS/FS/Template_Mixin.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/FS/FS/Template_Mixin.pm b/FS/FS/Template_Mixin.pm index 025e0d140..adab9d5e2 100644 --- a/FS/FS/Template_Mixin.pm +++ b/FS/FS/Template_Mixin.pm @@ -2239,7 +2239,9 @@ sub _items_cust_bill_pkg { # start/end dates for invoice formats that do nonstandard # things with them - my %item_dates = map { $_ => $cust_bill_pkg->$_ } ('sdate', 'edate'); + my %item_dates = (); + %item_dates = map { $_ => $cust_bill_pkg->$_ } ('sdate', 'edate') + unless $cust_pkg->part_pkg->option('disable_line_item_date_ranges',1); if ( (!$type || $type eq 'S') && ( $cust_bill_pkg->setup != 0 -- 2.11.0