Class PriceManager
- Namespace
- Dynamicweb.Ecommerce.Prices
- Assembly
- Dynamicweb.Ecommerce.dll
Represents a price manager. Provides prepares and finds prices.
public class PriceManager
- Inheritance
-
PriceManager
- Inherited Members
Examples
Methods
FindInformativePrice(Product)
Finds the informative price.
[Obsolete("Use overload with PriceContext")]
public static object FindInformativePrice(Product product)
Parameters
productProduct- The product.
Returns
- object
- The found price.
FindInformativePrice(Product, double)
Finds the informative price.
[Obsolete("Use overload with PriceContext")]
public static object FindInformativePrice(Product product, double quantity)
Parameters
Returns
- object
- The found price.
FindInformativePrice(Product, double, string, Currency)
Finds the informative price.
[Obsolete("Use overload with PriceContext")]
public static object FindInformativePrice(Product product, double quantity, string variantId, Currency currency)
Parameters
productProduct- The product.
quantitydouble- The quantity.
variantIdstring- The variant ID.
currencyCurrency- The currency.
Returns
- object
- The found price.
FindInformativePrice(Product, double, string, Currency, string)
Finds the informative price.
[Obsolete("Use overload with PriceContext")]
public static object FindInformativePrice(Product product, double quantity, string variantId, Currency currency, string unitId)
Parameters
productProduct- The product.
quantitydouble- The quantity.
variantIdstring- The variant ID.
currencyCurrency- The currency.
unitIdstring- The unit ID.
Returns
- object
- The found price.
FindPrice(PriceContext, PriceProductSelection, bool)
public static object FindPrice(PriceContext context, PriceProductSelection selection, bool isInformative)
Parameters
contextPriceContextselectionPriceProductSelectionisInformativebool
Returns
FindPrice(PriceContext, Product, string, long, bool)
public static object FindPrice(PriceContext context, Product product, string unitId, long stockLocationId, bool isInformative)
Parameters
contextPriceContextproductProductunitIdstringstockLocationIdlongisInformativebool
Returns
FindPrice(Product)
Finds the price.
[Obsolete("Use overload with PriceContext")]
public static object FindPrice(Product product)
Parameters
productProduct- The product.
Returns
- object
- The found price.
Examples
FindPrice(Product, double)
Finds the price.
[Obsolete("Use overload with PriceContext")]
public static object FindPrice(Product product, double quantity)
Parameters
Returns
- object
- The found price.
Examples
FindPrice(Product, double, string, Currency)
Finds the price.
[Obsolete("Use overload with PriceContext")]
public static object FindPrice(Product product, double quantity, string variantId, Currency currency)
Parameters
productProduct- The product.
quantitydouble- The quantity.
variantIdstring- The variant ID.
currencyCurrency- The currency.
Returns
- object
- The found price.
Examples
FindPrice(Product, double, string, Currency, string)
Finds the price.
[Obsolete("Use overload with PriceContext")]
public static object FindPrice(Product product, double quantity, string variantId, Currency currency, string unitId)
Parameters
productProduct- The product.
quantitydouble- The quantity.
variantIdstring- The variant ID.
currencyCurrency- The currency.
unitIdstring- The unit ID.
Returns
- object
- The found price.
Examples
FindPrice(Product, double, string, Currency, string, double)
Finds the price.
[Obsolete("Use overload with PriceContext")]
public static object FindPrice(Product product, double quantity, string variantId, Currency currency, string unitId, double quantityAllVariants)
Parameters
productProduct- The product.
quantitydouble- The quantity.
variantIdstring- The variant ID.
currencyCurrency- The currency.
unitIdstring- The unit ID.
quantityAllVariantsdouble- The quantity of all variants.
Returns
- object
- The found price.
GetInformativePrice(PriceContext, Product)
Gets the informative price for a given product.
public static PriceInfo GetInformativePrice(PriceContext context, Product product)
Parameters
contextPriceContext- Price context
productProduct- Product
Returns
- PriceInfo
- Informative price
GetInformativePrice(PriceContext, Product, string, long)
Gets the informative price for a given product.
public static PriceInfo GetInformativePrice(PriceContext context, Product product, string unitId, long stockLocationId)
Parameters
contextPriceContext- Price context
productProduct- Product
unitIdstring- Unit identifier
stockLocationIdlong- Stock location identifier
Returns
- PriceInfo
- Informative price
GetInformativePrice(Product, string, string)
Gets the informative price.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetInformativePrice(Product product, string currencyCode, string vatGroupCode)
Parameters
Returns
GetInformativePrice(Product, string, string, string)
Gets the informative price.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetInformativePrice(Product product, string unitId, string currencyCode, string vatGroupCode)
Parameters
Returns
GetInformativePrice(Product, string, string, string, string)
Gets the informative price.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetInformativePrice(Product product, string unitId, string currencyCode, string vatGroupCode, string shopId)
Parameters
productProductunitIdstringcurrencyCodestring- Currency code
vatGroupCodestring- Vat group code
shopIdstring- Country code2
Returns
GetInformativePrice(Product, string, string, string, string, StockLocation)
Gets the informative price.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetInformativePrice(Product product, string unitId, string currencyCode, string vatGroupCode, string shopId, StockLocation stockLocation)
Parameters
productProductunitIdstringcurrencyCodestring- Currency code
vatGroupCodestring- Vat group code
shopIdstring- Country code2
stockLocationStockLocation- The stock location.
Returns
GetInformativePrice(Product, string, string, string, string, StockLocation, int)
Gets the informative price.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetInformativePrice(Product product, string unitId, string currencyCode, string vatGroupCode, string shopId, StockLocation stockLocation, int userId)
Parameters
productProductunitIdstringcurrencyCodestring- Currency code
vatGroupCodestring- Vat group code
shopIdstring- Country code2
stockLocationStockLocation- The stock location.
userIdint
Returns
GetPrice(PriceContext, Product)
Gets the price for a given product.
public static PriceInfo GetPrice(PriceContext context, Product product)
Parameters
contextPriceContext- Price context
productProduct- Product
Returns
- PriceInfo
- Price
GetPrice(PriceContext, Product, string, long)
Gets the price for a given product.
public static PriceInfo GetPrice(PriceContext context, Product product, string unitId, long stockLocationId)
Parameters
contextPriceContext- Price context
productProduct- Product
unitIdstring- Unit identifier
stockLocationIdlong- Stock location identifier
Returns
- PriceInfo
- Price
GetPrice(Product, string, string, int)
Gets the price. This is the final calculated price for the product.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetPrice(Product product, string currencyCode, string countryCode, int userId)
Parameters
productProduct- The product
currencyCodestring- Currency code
countryCodestring- Country code
userIdint- The user id.
Returns
GetPrice(Product, string, string, string)
Gets the price. This is the final calculated price for the product.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetPrice(Product product, string currencyCode, string countryCode, string unitId)
Parameters
productProduct- The product
currencyCodestring- Currency code
countryCodestring- Country code
unitIdstring- The unit id.
Returns
GetPrice(Product, string, string, string, int)
Gets the price. This is the final calculated price for the product.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetPrice(Product product, string currencyCode, string countryCode, string unitId, int userId)
Parameters
productProduct- The product
currencyCodestring- Currency code
countryCodestring- Country code
unitIdstring- The unit id.
userIdint- The user id.
Returns
GetPrice(Product, string, string, string, int, string)
Gets the price. This is the final calculated price for the product.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetPrice(Product product, string currencyCode, string countryCode, string unitId, int userId, string shopId)
Parameters
productProduct- The product
currencyCodestring- Currency code
countryCodestring- Country code
unitIdstring- The unit id.
userIdint- The user id.
shopIdstring- The shop id.
Returns
GetPrice(Product, string, string, string, int, string, StockLocation)
Gets the price. This is the final calculated price for the product.
[Obsolete("Use overload with PriceContext")]
public static PriceInfo GetPrice(Product product, string currencyCode, string countryCode, string unitId, int userId, string shopId, StockLocation stockLocation)
Parameters
productProduct- The product
currencyCodestring- Currency code
countryCodestring- Country code
unitIdstring- The unit id.
userIdint- The user id.
shopIdstring- The shop id.
stockLocationStockLocation- The stock location.
Returns
PreparePrices(PriceContext, IEnumerable<PriceProductSelection>)
Prepares the prices.
public static void PreparePrices(PriceContext context, IEnumerable<PriceProductSelection> selections)
Parameters
contextPriceContext- The price context.
selectionsIEnumerable<PriceProductSelection>- The product selections.
PreparePrices(PriceContext, IEnumerable<Product>)
Prepares the prices.
public static void PreparePrices(PriceContext context, IEnumerable<Product> products)
Parameters
contextPriceContext- The price context.
productsIEnumerable<Product>- The products.
PreparePrices(PriceContext, IEnumerable<Product>, long)
Prepares the prices.
public static void PreparePrices(PriceContext context, IEnumerable<Product> products, long stockLocationId)
Parameters
contextPriceContext- The price context.
productsIEnumerable<Product>- The products.
stockLocationIdlong- Stock location identifier
PreparePrices(ProductCollection)
Prepares the prices.
[Obsolete("Use overload with PriceContext")]
public static void PreparePrices(ProductCollection products)
Parameters
productsProductCollection- The products.
PreparePrices(Dictionary<Product, double>)
Prepares the prices.
[Obsolete("Use overload with PriceContext")]
public static void PreparePrices(Dictionary<Product, double> products)
Parameters
productsDictionary<Product, double>- The products.
PreparePrices(IEnumerable<Product>)
Prepares the prices.
[Obsolete("Use overload with PriceContext")]
public static void PreparePrices(IEnumerable<Product> products)
Parameters
productsIEnumerable<Product>- The products.