Carrier Per Carton Fee

Navigation:  Customer > Billing Wizard > Per Transaction Billing Setup > AutoBilling Scripts >

Carrier Per Carton Fee

Previous pageReturn to chapter overviewNext page

Description: Tiered rates base on carrier selection and quantity of cartons (Num Units 1)

Script:

Customer-BillingWizard-PerTransBill-AutoBill-Script109

User Input:

Customer-BillingWizard-PerTransBill-AutoBill-Script109Setup

Explanation: Default charge, tiered charges, and Carrier selections.  If the wt.Carrier value matches on of the Carriers defined in the script setup, we'll create a charge object, assign the number of units based on Num Units 1, add Num Units 1 to the description, start with the default charge, and then check through the tiered charges for a tier Amount that is less than or equal to Num Units 1.  If we find one we set the ChargePerUnit equal to the matching TierPrice, and then we're done.