Cart name:
Select the cart you want change the configuration settings.
Save cart in cookie:
If checked the cart is saved in cookie, otherwise the cart is saved in a server side session variable. The difference between the 2 method is:
The cookie is persintent for a time you can configure and the server side session variable is dependent on the server configuration but it is usually maintained for up to 20 minutes of inactivity.
Expire cookie days:
The number of days the cookie is maintained in the client, so if a user decides to leave and then come back, his or her cart will still contain the same products that was placed in the cart. If this value is set to 0 (zero) will keep the cart contents for the session only. If this value is set to -1 the cookie is disable and only maintain information via a server side session variable.
In order to use session variables remember to start the session.
To start session you must put this lines of code in the top of each page:
<?php
if(!isset($_SESSION)){
session_start();
}
?>
Session name:
The name of the session variable where store the order IdRecord.
LCID:
This property this will set the server to the correct geographic location or region to help with format issues, such as currency, date, and time, that are specific to an area.
Default value us 1033 ~ English - United States
Other LCID:
2057 ~ English - United Kingdom
4105 ~ English - Canada
5129 ~ English - New Zealand
1030 ~ Italy
See
Microsoft for a complete list of LCIDs.
Columns:
This will be the columns you have in the cart.
The default cart contains this columns:
- IdProduct (*)
- Quantity (*)
- ProductName
- UnitPrice (*)
- Discount (*)
- ShippingCost (*)
- UnitWeight (*)
- VATperc (*)
- ItemDiscount (*)
- TotalDiscount (*)
- TotalPrice (*)
- TotalWeight (*)
The columns marked with (*) cannot be deleted or renamed.
The ShippingCost is a boolean value, true as default. The ShippingAmount is calculated only for the product where the ShippingCost columns is true.
You can add all the others field you need except you can not use these reserved names:
- IdProduct
- Quantity
- UnitPrice
- Discount
- ShippingCost
- UnitWeight
- VATperc
- ItemDiscount
- TotalDiscount
- TotalPrice
- TotalWeight
Column name:
The column cart name can be made up of alphanumeric characters and the underscore [A-Za-z0-9_]. The name entered here will be used to identify the cart's column and it's contents.
Column formula:
This is an expression property that is used to create calculated columns. You can use almost any type of arithmetic operator and the round parentesis to compute all you need to do is to enclose the cart column names in brackets e.g. [CartColumn]. This formula can also contains calculated columns.
For example to calculate the item net price we can enter:
[Price] - ( [Price] * [Discount] / 100)
To Format a number to 2 decimals you can use:
round([Price] - ( [Price] * [Discount] / 100),2)
In case you need call your own function you can use this syntax:
YourFunction()
You can also send parameters to your function and in this case the parameters value must be enclosed in simple apex like:
YourFunction('[IdProduct]','[Quantity]')
Column level:
The calculated columns can be used in a formula, so you must define the order the cart use to calculate the calculated columns from the min to the max. This is to prevent a formula with a calculate columns is calculate before the calculate column.
For example imagine to have 2 columns:
TotalPrice = [UnitePrice] * [Quantity]
NewValue = [TotalPrice] * 1.2
In this case the ColumnLevel of the TotalPrice must be less than the ColumnLevel of the NewValue column, because the cart must calculte before the value of the TotalPrice and after the value of the NewValue column.
Column sum:
If checked a leaf nodes is added to the DataSource and will be the column sum. A sum of the column value for all the product in the cart.