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))
 
m (Edit via perl MediaWiki framework (1.13))
Line 8: Line 8:
  
 
; calc_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.
+
: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.
  
 
==POD ERRORS==
 
==POD ERRORS==

Revision as of 06:49, 10 February 2015

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.

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'