[freeside-commits] freeside/FS/FS/cust_main Billing.pm,1.37,1.38
Ivan,,,
ivan at wavetail.420.am
Tue Jul 12 15:57:06 PDT 2011
Update of /home/cvs/cvsroot/freeside/FS/FS/cust_main
In directory wavetail.420.am:/tmp/cvs-serv31465/FS/FS/cust_main
Modified Files:
Billing.pm
Log Message:
fix UI for package editing w/recur_show_zero, add setup_show_zero, RT#9777
Index: Billing.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_main/Billing.pm,v
retrieving revision 1.37
retrieving revision 1.38
diff -u -w -d -r1.37 -r1.38
--- Billing.pm 12 Jul 2011 07:54:22 -0000 1.37
+++ Billing.pm 12 Jul 2011 22:57:04 -0000 1.38
@@ -616,15 +616,18 @@
&& scalar(@{$cust_bill_pkg->get('discounts')})
&& $conf->exists('discount-show-always'));
- warn " pkgnum ". $cust_bill_pkg->pkgnum.
- " sum $sum, recur_show_zero ". $cust_bill_pkg->recur_show_zero. "\n"
+ warn " pkgnum ". $cust_bill_pkg->pkgnum. " sum $sum, ".
+ "setup_show_zero ". $cust_bill_pkg->setup_show_zero.
+ "recur_show_zero ". $cust_bill_pkg->recur_show_zero. "\n"
if $DEBUG > 0;
if (scalar(@cust_bill_pkg_bundle) && !$cust_bill_pkg->pkgpart_override) {
push @cust_bill_pkg, @cust_bill_pkg_bundle
if $sum > 0
|| ($sum == 0 && ( $discount_show_always
- || grep $_->recur_show_zero, @cust_bill_pkg_bundle )
+ || grep {$_->recur_show_zero || $_->setup_show_zero}
+ @cust_bill_pkg_bundle
+ )
);
@cust_bill_pkg_bundle = ();
$sum = 0;
@@ -638,7 +641,9 @@
push @cust_bill_pkg, @cust_bill_pkg_bundle
if $sum > 0
|| ($sum == 0 && ( $discount_show_always
- || grep $_->recur_show_zero, @cust_bill_pkg_bundle )
+ || grep {$_->recur_show_zero || $_->setup_show_zero}
+ @cust_bill_pkg_bundle
+ )
);
warn " _omit_zero_value_bundles: ". scalar(@in).
@@ -1048,7 +1053,8 @@
|| $recur != 0
|| (!$part_pkg->hidden && $options{has_hidden}) #include some $0 lines
|| $discount_show_always
- || ($recur == 0 && $part_pkg->recur_show_zero)
+ || ($setup == 0 && $cust_pkg->_X_show_zero('setup'))
+ || ($recur == 0 && $cust_pkg->_X_show_zero('recur'))
)
{
More information about the freeside-commits
mailing list