![]() |
![]()
| ![]() |
![]()
NAMEInterchange6::Cart::Cost - Cart cost class for Interchange6 Shop Machine DESCRIPTIONCart cost class for Interchange6. ATTRIBUTESidCart id can be used for subclasses, e.g. primary key value for cart or product costs in the database. nameUnique name is required. labelLabel for display. Default is same value as label. relativeBoolean defaults to 0. If true then amount is relative to object subtotal. If false then amount is an absolute cost. inclusiveBoolean defaults to 0. If true signifies that the cost is already included in the price for example to calculate the tax component for gross prices. compoundBoolean defaults to 0. If true signifies that any following costs should be applied to the modified price after this cost has been applied. This might be used for such things as discounts which are applied before taxes are applied to the modified price. Using "compound" along with "inclusive" makes no sense and no guarantee is given as to what the result might be. amountRequired amount of the cost. This is the absolute cost unless "relative" is true in which case it is relative to the object subtotal. For example for a tax of 8% amount should be set to 0.08 current_amountCalculated current amount of cost. Unless "relative" is true this will be the same as "amount". If "relative" is true then this is value is recalulated whenever "total" is called on the object.
|