Class ProductExtentions
- Namespace
- Dynamicweb.Ecommerce.Products
- Assembly
- Dynamicweb.Ecommerce.dll
- Inheritance
-
Product
Extentions
- Inherited Members
Methods
GetCategoryValue(Product, string, string, bool)
Retrieves the value of the given category field.
public static object GetCategoryValue(this Product product, string categoryId, string fieldId, bool includeInheritance)
Parameters
product
ProductcategoryId
stringAn ID (system name) of the category.
fieldId
stringAn ID of the target category field.
includeInheritance
bool
Returns
- object
Category field value.
GetDefaultGroup(Product)
Gets primary or default group
Parameters
product
Product
Returns
- Group
Primary or default group
GetDefaultGroupByShopId(Product, string)
Gets the default group by shop id.
Parameters
Returns
- Group
Group.
GetDefaultGroupByShopId(Product, string, bool)
Gets the default group by shop id.
public static Group GetDefaultGroupByShopId(this Product product, string ShopId, bool checkForPrimaryGroup)
Parameters
Returns
- Group
Group.
GetInformativePrice(Product, PriceContext)
Gets the informative price.
Parameters
product
Productcontext
PriceContext Price context
Returns
GetInformativePrice(Product, PriceContext, string, long)
Gets the informative price.
public static PriceInfo GetInformativePrice(this Product product, PriceContext context, string unitId, long stockLocationId)
Parameters
product
Productcontext
PriceContext Price context
unitId
stringUnit identifier
stockLocationId
longStock location identifier
Returns
GetIsVariantMaster(Product)
Gets the value that indicates if the variant is a master.
Parameters
product
Product
Returns
GetLanguage(Product)
Parameters
product
Product
Returns
GetOrderLineFields(Product)
Gets the order line fields.
Parameters
product
Product
Returns
- Order
Line Field Collection The order line fields.
GetPrice(Product, PriceContext)
Gets the price. This is the final calculated price for the product.
Parameters
product
Productcontext
PriceContext Price context
Returns
GetPrice(Product, PriceContext, string, long)
Gets the price. This is the final calculated price for the product.
public static PriceInfo GetPrice(this Product product, PriceContext context, string unitId, long stockLocationId)
Parameters
product
Productcontext
PriceContext Price context
unitId
stringUnit identifier
stockLocationId
longStock location identifier
Returns
GetPrices(Product)
Gets prices for the product.
Parameters
product
ProductThe product.
Returns
GetPrimaryGroupId(Product)
Gets the ID of primary group
Parameters
product
Product
Returns
- string
Primary group ID
GetProductKey(Product)
Parameters
product
Product
Returns
GetUnitStock(Product, StockLocation, string)
Gets the stock of the current product instance based on the provider if any are specified. Goes through the stock level provider (and hence the ERP if configured to do that). If there are not providers, 0.0 is returned
Parameters
product
ProductstockLocation
StockLocation unitId
string
Returns
GetVariantCombinations(Product)
Gets VariantCombinationCollection object.
Parameters
product
Product
Returns
GetVariantCombinationsWithStockCheck(Product)
Gets VariantCombinationCollection object.
Parameters
product
Product
Returns
GetVariantCount(Product)
Gets the variant counting.
Parameters
product
Product
Returns
SetCategoryValue(Product, string, Field, object)
Assigns category field value to the current product.
public static void SetCategoryValue(this Product product, string categoryId, Field field, object value)