X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=FS%2FFS%2Fpart_pkg%2Fflat.pm;h=cfee58465b3032f58cc2f0953d93f9cd651176ec;hp=6fd9c7d0857eb7c428b4a18f5638fcd587bb3f69;hb=d263897b2b9247340901f93c57f44c7f85d87d37;hpb=e322fbb08d0f837be3f3f8e7c92a4a5bc75030ad diff --git a/FS/FS/part_pkg/flat.pm b/FS/FS/part_pkg/flat.pm index 6fd9c7d08..cfee58465 100644 --- a/FS/FS/part_pkg/flat.pm +++ b/FS/FS/part_pkg/flat.pm @@ -128,12 +128,13 @@ sub calc_setup { my $discount = 0; if ( $charge > 0 ) { - $param->{'setup_charge'} = $charge; - $discount = $self->calc_discount($cust_pkg, $sdate, $details, $param); - delete $param->{'setup_charge'}; + $param->{'setup_charge'} = $charge; + $discount = $self->calc_discount($cust_pkg, $sdate, $details, $param); + delete $param->{'setup_charge'}; } sprintf( '%.2f', ($cust_pkg->quantity || 1) * ($charge - $discount) ); + } sub base_setup {