SKUInfoProviderGetSKUPrice Method (SKUInfo, ShoppingCartInfo, Boolean, Boolean, Boolean, String, SKUInfo, Double) |
Returns product catalog price based on the SKU data and shopping cart data.
Catalog discounts and/or taxes are included optionally. Result is in site main currency.
Namespace: CMS.EcommerceAssembly: CMS.Ecommerce (in CMS.Ecommerce.dll) Version: 8.2.23
Syntax public static double GetSKUPrice(
SKUInfo sku,
ShoppingCartInfo cart,
bool discounts,
bool taxes,
bool forCart = false,
string column = null,
SKUInfo parentSku = null,
double customPrice = Není číslo
)
Parameters
- sku
- Type: CMS.EcommerceSKUInfo
SKU data - cart
- Type: CMS.EcommerceShoppingCartInfo
Shopping cart data - discounts
- Type: SystemBoolean
True - catalog discounts are applied to the price - taxes
- Type: SystemBoolean
True - catalog taxes are applied to the discounted price - forCart (Optional)
- Type: SystemBoolean
True - This method is called within the shopping cart calculations, False (default) - This method is called within the displaying price on the live site. - column (Optional)
- Type: SystemString
Name of the column the price should be retrieved from. If empty, SKUPrice column is used. - parentSku (Optional)
- Type: CMS.EcommerceSKUInfo
The parent SKU for option(SKU) price calculation. Parent SKU taxes and discounts will be used. - customPrice (Optional)
- Type: SystemDouble
If set, sku price is not taken from SKUInfo object.
Return Value
Type:
DoubleSee Also