Class SerializableLineItem
This type/member supports the EPiServer infrastructure and is not intended to be used directly from your code.
This class represents a line item in the new cart system. It works with the new database model for cart.
Inheritance
Implements
Inherited Members
Namespace: EPiServer.Commerce.Order.Internal
Assembly: EPiServer.Business.Commerce.dll
Version: 13.30.0Syntax
public class SerializableLineItem : ILineItem, IExtendedProperties, ILineItemInventory, ILineItemDiscountAmount, ILineItemCalculatedAmount
Constructors
SerializableLineItem()
Creates an instance of SerializableLineItem.
Declaration
public SerializableLineItem()
SerializableLineItem(Int32, String)
Creates an instance of SerializableLineItem. This constructor is required for the JSON deserializer to be able to set the readonly properties.
Declaration
public SerializableLineItem(int lineItemId, string code)
Parameters
Type | Name | Description |
---|---|---|
System.Int32 | lineItemId | The line item id. |
System.String | code | The line item code. |
Properties
AllowBackordersAndPreorders
Gets or sets a value indicating whether [allow backorders and preorders].
Declaration
[Obsolete("This property is no longer used.")]
public bool AllowBackordersAndPreorders { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
BackorderQuantity
Gets or sets the backorder quantity.
Declaration
[Obsolete("This property is no longer used. Inventory information can be retrieved using IInventoryService. Will remain at least until June 2019.")]
public decimal BackorderQuantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
Code
Gets the code of the variation content the line item represent. This property works as the connection between the line item and the variation content.
Declaration
public string Code { get; }
Property Value
Type | Description |
---|---|
System.String |
DisplayName
Gets or sets the display name.
Declaration
public string DisplayName { get; set; }
Property Value
Type | Description |
---|---|
System.String |
EntryAmount
Gets or sets the discount amount set for this specific line item. This property is normally set by the promotion system.
Declaration
public decimal EntryAmount { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
InStockQuantity
Gets or sets the in stock quantity.
Declaration
[Obsolete("This property is no longer used. Inventory information can be retrieved using IInventoryService. Will remain at least until June 2019.")]
public decimal InStockQuantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
InventoryStatus
Gets or sets the inventory status.
Declaration
[Obsolete("This property is no longer used. Inventory information can be retrieved using IInventoryService. Will remain at least until June 2019.")]
public int InventoryStatus { get; set; }
Property Value
Type | Description |
---|---|
System.Int32 |
InventoryTrackingStatus
Gets or sets the inventory tracking status on whether to check inventory.
Declaration
public InventoryTrackingStatus InventoryTrackingStatus { get; set; }
Property Value
Type | Description |
---|---|
InventoryTrackingStatus |
IsGift
Gets or sets a value indicating whether the line item is a gift item.
Declaration
public bool IsGift { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
|
IsInventoryAllocated
Gets or sets a value indicating whether this instance has allocated inventory for the Quantity.
Declaration
public bool IsInventoryAllocated { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
IsSalesTaxUpToDate
Gets or sets the flag indicating whether the SalesTax. is up-to-date.
Declaration
public bool IsSalesTaxUpToDate { get; set; }
Property Value
Type | Description |
---|---|
System.Boolean |
LineItemId
Gets the identity of the line item.
Declaration
public int LineItemId { get; }
Property Value
Type | Description |
---|---|
System.Int32 |
MaxQuantity
Gets or sets the max quantity.
Declaration
[Obsolete("This property is no longer used. Inventory information can be retrieved using IInventoryService. Will remain at least until June 2019.")]
public decimal MaxQuantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
MinQuantity
Gets or sets the min quantity.
Declaration
[Obsolete("This property is no longer used. Inventory information can be retrieved using IInventoryService. Will remain at least until June 2019.")]
public decimal MinQuantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
OrderAmount
Gets the discount amount not specifically set for this line item. This property contains the total order level discount for the whole order divided by the number of line items the order contains.
Declaration
public decimal OrderAmount { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal | The order level discount amount. |
ParentOrderGroup
Gets the parent order group.
Declaration
public IOrderGroup ParentOrderGroup { get; }
Property Value
Type | Description |
---|---|
IOrderGroup |
PlacedPrice
Gets or sets the price for one item that this line item represent. This property don't take any discounts in consideration.
Declaration
public decimal PlacedPrice { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
PreorderQuantity
Gets or sets the preorder quantity.
Declaration
[Obsolete("This property is no longer used. Inventory information can be retrieved using IInventoryService. Will remain at least until June 2019.")]
public decimal PreorderQuantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
Properties
Gets or sets the property bag for dealing with custom meta fields.
Declaration
public Hashtable Properties { get; set; }
Property Value
Type | Description |
---|---|
System.Collections.Hashtable |
Quantity
Gets or sets the number of items this line item contains.
Declaration
public decimal Quantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
ReturnQuantity
Gets or sets the returned in stock quantity.
Declaration
public decimal ReturnQuantity { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
SalesTax
Gets or sets the sales tax amount.
Declaration
public decimal SalesTax { get; set; }
Property Value
Type | Description |
---|---|
System.Decimal |
TaxCategoryId
Gets or sets the tax category id.
Declaration
public int? TaxCategoryId { get; set; }
Property Value
Type | Description |
---|---|
System.Nullable<System.Int32> |
Explicit Interface Implementations
ILineItemCalculatedAmount.PricesIncludeTax
Gets the setting of including tax in price from the order group.
Declaration
bool ILineItemCalculatedAmount.PricesIncludeTax { get; }
Returns
Type | Description |
---|---|
System.Boolean |
Remarks
It does not need to be included in serialization.