diff options
author | Jonathan Prykop <jonathan@freeside.biz> | 2016-06-03 19:54:20 -0500 |
---|---|---|
committer | Jonathan Prykop <jonathan@freeside.biz> | 2016-06-03 19:54:20 -0500 |
commit | c6c69f3dceb427a8377cc49a44a16be16d822948 (patch) | |
tree | e3c25475598a79a4d36704c6130a53fa326b7fb5 /FS | |
parent | 79d69cc33b1c61c37ec969fa763708c31fdfb590 (diff) | |
parent | cf630a513689c8a176a6a552fcbcba844a0d5b76 (diff) |
Merge branch 'FREESIDE_4_BRANCH' of git.freeside.biz:/home/git/freeside into FREESIDE_4_BRANCH
Diffstat (limited to 'FS')
-rw-r--r-- | FS/FS/cust_main/Billing.pm | 1 | ||||
-rw-r--r-- | FS/FS/part_pkg/sql_external.pm | 3 |
2 files changed, 2 insertions, 2 deletions
diff --git a/FS/FS/cust_main/Billing.pm b/FS/FS/cust_main/Billing.pm index 47a3dc2d4..d95376798 100644 --- a/FS/FS/cust_main/Billing.pm +++ b/FS/FS/cust_main/Billing.pm @@ -1172,6 +1172,7 @@ sub _make_lines { if ( $param{'override_quantity'} ) { $override_quantity = $param{'override_quantity'}; + $unitrecur = $recur / $override_quantity; } if ( $increment_next_bill ) { diff --git a/FS/FS/part_pkg/sql_external.pm b/FS/FS/part_pkg/sql_external.pm index 676063460..9bf107b7d 100644 --- a/FS/FS/part_pkg/sql_external.pm +++ b/FS/FS/part_pkg/sql_external.pm @@ -96,8 +96,7 @@ sub calc_recur { die "sql_external query returned non-numeric amount: $row->{amount}"; } } - if (exists $row->{quantity}) { - $quantity ||= 0; + if (defined $row->{quantity}) { if ( $row->{quantity} eq '' ) { # treat as zero } elsif ( $row->{quantity} =~ /^\d+$/ ) { |