OrderDiscountManager
OrderDiscountManager class for handling shopping cart discounts during calculations.
Class methods
Method | Description | Available from version |
---|---|---|
calculateApplyCoupons | Used for applying discounts with module coupons (except online Store module coupons) to products of saved order. Discounts are calculated from price, saved in order. | |
checkDiscountProvider | Checks if discount provider exist for module. | |
createSimpleDescription | Creates a simple description for an arbitrary shopping cart discount. | |
deleteByOrder | Deletes information about applied order discounts. | |
formatArrayDescription | Returns description of shopping cart discount (value and action) using passed data. Used for generating discount description at the order page. | |
formatDescription | Helper method. Calls method formatDiscountDescription and depending on its returned value - returns string (on success) or false (on error). | |
formatDiscountDescription | Formats shopping cart discount description, returns object. | |
getEditUrl | Returns address for discount edit page in the site admin section. | |
getManagerConfig | Returns current parameters for shopping cart manager. | |
init | Initializes shopping cart discount manager. | |
loadResultFromDatabase | Loads complete information on applied discounts, price rounding off and order settings, necessary for discount calculations. | |
prepareDiscountDescription | Returns shopping cart description. | |
saveCoupon | Saves a coupon. | |
saveDiscount | Converts and saves shopping cart rule. | |
setManagerConfig | Sets parameters for shopping cart discount manager. |
© «Bitrix24», 2001-2024