Difference between revisions of "Freeside:3:Documentation:Developer/FS/part pkg/discount Mixin"

From Freeside
Jump to: navigation, search
m (Edit via perl MediaWiki framework (1.13))
(No difference)

Revision as of 21:08, 27 June 2012

NAME

FS::part_pkg::discount_Mixin - Mixin class for part_pkg:: classes that can be discounted.

SYNOPSIS

package FS::part_pkg::...; use base qw( FS::part_pkg::discount_Mixin );

sub calc_recur { ... my $discount = $self->calc_discount($cust_pkg, $$sdate, $details, $param); $charge -= $discount; ... }

calc_discount
Takes all the arguments of calc_recur. Calculates and returns the amount by which to reduce the recurring fee; also increments months used on the discount and generates an invoice detail describing it.

POD ERRORS

Hey! The above document had some coding errors, which are explained below:

Around line 29:
Unknown directive: =head
Around line 31:
'=item' outside of any '=over'