Class CustomerProductListProduct
- Namespace
- Dynamicweb.Ecommerce.CustomerCenter
- Assembly
- Dynamicweb.Ecommerce.dll
CustomerProductListProduct class.
public class CustomerProductListProduct : DbObject
- Inheritance
-
CustomerProductListProduct
- Inherited Members
Constructors
CustomerProductListProduct()
Initializes a new instance of the CustomerProductListProduct class.
public CustomerProductListProduct()
- See Also
Properties
ListId
Gets or sets the list identifier.
public int ListId { get; set; }
Property Value
- int
- The list identifier.
- See Also
Note
Gets or sets the note.
public string Note { get; set; }
Property Value
- string
- The note.
- See Also
ProductId
Gets or sets the product identifier.
public string ProductId { get; set; }
Property Value
- string
- The product identifier.
- See Also
ProductLanguageId
Gets or sets the product language identifier.
[Obsolete("Not used")]
public string ProductLanguageId { get; set; }
Property Value
- string
- The product language identifier.
- See Also
ProductReferenceUrl
Gets or sets the product reference URL.
public string ProductReferenceUrl { get; set; }
Property Value
- string
- The product reference URL.
- See Also
ProductVariantId
Gets or sets the product variant identifier.
public string ProductVariantId { get; set; }
Property Value
- string
- The product variant identifier.
- See Also
Quantity
Gets or sets the quantity.
public int Quantity { get; set; }
Property Value
- int
- The quantity.
- See Also
SortOrder
Gets or sets the sort order.
public int SortOrder { get; set; }
Property Value
- int
- The sort order.
- See Also
Methods
ClearCache(int, string, string)
Clears the cache.
public static void ClearCache(int favoriteListId, string productId, string variantId)
Parameters
favoriteListIdint- The favorite list identifier.
productIdstring- The product identifier.
variantIdstring- The product variant identifier.
- See Also
ClearCache(int, string, string, string)
[Obsolete("Use the overload without Language ID")]
public static void ClearCache(int favoriteListId, string productId, string variantId, string languageId)
Parameters
- See Also
Delete(int)
Deletes the object with specified Id.
public override void Delete(int id)
Parameters
idint- Specified Id.
- See Also
Fill(IDataReader)
Fills the specified reader.
public override void Fill(IDataReader reader)
Parameters
readerIDataReader- The reader.
- See Also
FillRow(DataRow)
Fills the row.
protected override void FillRow(DataRow row)
Parameters
rowDataRow- The row.
- See Also
GetPagedProductsByListId(int, int, int)
Gets range of products by favorites list id.
public static IEnumerable<CustomerProductListProduct> GetPagedProductsByListId(int id, int startIndex, int pageSize)
Parameters
idint- The id of favorites list.
startIndexint- The start index of range.
pageSizeint- The ammount of items.
Returns
- IEnumerable<CustomerProductListProduct>
- The range of products in favorites list
- See Also
GetProductById(int)
Gets product by id.
public static CustomerProductListProduct GetProductById(int favoriteProductId)
Parameters
favoriteProductIdint- The id of the favorite product.
Returns
- See Also
GetProductById(string, string)
Gets product by id.
public static CustomerProductListProduct GetProductById(string productId, string productVariantId)
Parameters
Returns
- See Also
GetProductById(string, string, string)
[Obsolete("Use the overload without Language ID")]
public static CustomerProductListProduct GetProductById(string productId, string productLanguageId, string productVariantId)
Parameters
Returns
- See Also
GetProductByIdAndList(int, string, string)
Gets product by id and favorite list Id.
public static CustomerProductListProduct GetProductByIdAndList(int listId, string productId, string productVariantId)
Parameters
listIdint- The favorite list Id.
productIdstring- The id of the product.
productVariantIdstring- The variant id of the product.
Returns
- CustomerProductListProduct
- The favorite product
- See Also
GetProductByIdAndList(int, string, string, string)
[Obsolete("Use the overload without Language ID")]
public static CustomerProductListProduct GetProductByIdAndList(int listId, string productId, string productLanguageId, string productVariantId)
Parameters
Returns
- See Also
GetProductsByIds(IEnumerable<string>)
Gets products by ids.
public static IEnumerable<CustomerProductListProduct> GetProductsByIds(IEnumerable<string> productIds)
Parameters
productIdsIEnumerable<string>- The ids of the favorite products.
Returns
- See Also
GetProductsByIds(IEnumerable<string>, string)
[Obsolete("Use the overload without Language ID")]
public static IEnumerable<CustomerProductListProduct> GetProductsByIds(IEnumerable<string> productIds, string languageId)
Parameters
productIdsIEnumerable<string>languageIdstring
Returns
- See Also
GetProductsByListId(int)
Gets products by favorites list id.
public static IEnumerable<CustomerProductListProduct> GetProductsByListId(int id)
Parameters
idint- The id of favorites list.
Returns
- IEnumerable<CustomerProductListProduct>
- The products in favorites list
- See Also
GetProductsByListPublishedId(string)
Gets products by favorites list published id.
public static IEnumerable<CustomerProductListProduct> GetProductsByListPublishedId(string publishedId)
Parameters
publishedIdstring- The published id of favorites list.
Returns
- IEnumerable<CustomerProductListProduct>
- The products in favorites list
- See Also
GetProductsByUserId(int)
Gets favorites products by user id.
public static IEnumerable<CustomerProductListProduct> GetProductsByUserId(int userId)
Parameters
userIdint- The id of user.
Returns
- IEnumerable<CustomerProductListProduct>
- The products in favorites list
- See Also
GetProductsByUserId(int, bool)
Gets favorites products by user id.
public static IEnumerable<CustomerProductListProduct> GetProductsByUserId(int UserId, bool useCustomerNumberToRetrieveListsProducts)
Parameters
UserIdint- The id of user.
useCustomerNumberToRetrieveListsProductsbool- If True returns products for all all users with with current user customer number
Returns
- IEnumerable<CustomerProductListProduct>
- The products in favorites list
- See Also
IsProductInFavorites(Product)
Gets value which indicate whether product is in any favorite list.
public static bool IsProductInFavorites(Product product)
Parameters
productProduct- The product.
Returns
- bool
trueif product is in any favorite list; otherwise,false.
- See Also
IsProductInFavorites(Product, int)
Gets value which indicate whether product is in the favorite list.
public static bool IsProductInFavorites(Product product, int listId)
Parameters
Returns
- bool
trueif product is in the favorite list; otherwise,false.
- See Also
Save()
Saves current data to the database.
public override void Save()
- See Also
UpdateQuantity(string, string, int, int)
Updates the quantity.
public static void UpdateQuantity(string productId, string variantId, int favoriteListId, int quantity)
Parameters
productIdstring- The product identifier.
variantIdstring- The product variant identifier.
favoriteListIdint- The favorite list identifier.
quantityint- The quantity.
- See Also
UpdateQuantity(string, string, string, int, int)
[Obsolete("Use the overload without Language ID")]
public static void UpdateQuantity(string productId, string variantId, string languageId, int favoriteListId, int quantity)
Parameters
- See Also
UpdateSortOrder(ref string, int, int)
Updates the sort order.
public static void UpdateSortOrder(ref string productId, int favoriteListId, int sortOrder)
Parameters
productIdstring- The product identifier.
favoriteListIdint- The favorite list identifier.
sortOrderint- The sort order.
- See Also