CartExtension.CartItem
This Apex object represents an in-memory CartItem
record and its relationships with other records. All formula and roll-up summary standard fields are updated at runtime.
Loading and saving this object is not possible in Apex but is done by Salesforce.
See Object Reference: CartItem
Constructor for CartItem
object. All arguments are required.
Param | Description |
---|---|
salesItemType | Initial value for CartItem.Type . |
cartDeliveryGroup | Initial CartExtension.CartDeliveryGroup object related to this object. Its ID will be saved in CartItem.CartDeliveryGroupId . |
name | Initial value for CartItem.Name . |
Get the CartExtension.CartDeliveryGroup object whose ID was saved in CartItem.Id
.
Type | Description |
---|---|
CartDeliveryGroup | CartExtension.CartDeliveryGroup |
Set the related CartExtension.CartDeliveryGroup object whose ID is stored in CartItem.Id
on save.
Type | Description |
---|---|
void | CartExtension.CartDeliveryGroup |
Get the Parent CartExtension.CartItem object whose ID was saved in CartItem.Id
.
Type | Description |
---|---|
CartItem | CartExtension.CartItem |
Set the related Parent CartExtension.CartItem object whose ID is stored in CartItem.Id
on save.
Type | Description |
---|---|
void | CartExtension.CartItem |
Get all the related CartExtension.CartItem objects.
Type | Description |
---|---|
CartItemList | CartExtension.CartItemList |
Get CartItem.Type
.
Type | Description |
---|---|
SalesItemTypeEnum | CartExtension.SalesItemTypeEnum |
Get CartItem.SubType
.
Type | Description |
---|---|
CartItemSubTypeEnum | CartExtension.CartItemSubTypeEnum |
Set CartItem.SubType
.
Type | Description |
---|---|
void |
Get CartItem.Name
.
Type | Description |
---|---|
String |
Set CartItem.Name
.
Type | Description |
---|---|
void |
Get CartItem.Product2Id
.
Type | Description |
---|---|
ID |
Set CartItem.Product2Id
.
Type | Description |
---|---|
void |
Get CartItem.Sku
.
Type | Description |
---|---|
String |
Set CartItem.Sku
.
Type | Description |
---|---|
void |
Get CartItem.Quantity
.
Type | Description |
---|---|
Decimal |
Set CartItem.Quantity
.
Type | Description |
---|---|
void |
Get CartItem.ListPrice
.
Type | Description |
---|---|
Decimal |
Get CartItem.ListPrice
.
Type | Description |
---|---|
void |
Get CartItem.SalesPrice
.
Type | Description |
---|---|
Decimal |
Set CartItem.SalesPrice
.
Type | Description |
---|---|
void |
Get CartItem.UnitAdjustedPrice
.
Type | Description |
---|---|
Decimal |
Set CartItem.UnitAdjustedPrice
.
Type | Description |
---|---|
void |
Set CartItem.UnitItemAdjustmentAmount
.
Type | Description |
---|---|
void |
Get CartItem.UnitItemAdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.UnitAdjustedPriceWithItemAdj
.
Type | Description |
---|---|
void |
Get CartItem.UnitAdjustedPriceWithItemAdj
.
Type | Description |
---|---|
Decimal |
Set CartItem.TotalListPrice
.
Type | Description |
---|---|
void |
Get CartItem.TotalListPrice
.
Type | Description |
---|---|
Decimal |
Set CartItem.TotalFirstPymtListPrice
.
Type | Description |
---|---|
void |
Get CartItem.TotalFirstPymtListPrice
.
Type | Description |
---|---|
Decimal |
Get CartItem.TotalPrice
.
Type | Description |
---|---|
Decimal |
Set CartItem.TotalPrice
.
Type | Description |
---|---|
void |
Get CartItem.NetUnitPrice
.
Type | Description |
---|---|
Decimal |
Set CartItem.NetUnitPrice
.
Type | Description |
---|---|
void |
Get CartItem.GrossUnitPrice
.
Type | Description |
---|---|
Decimal |
Set CartItem.GrossUnitPrice
.
Type | Description |
---|---|
void |
Get CartItem.TotalLineTaxAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.ItemizedAdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.DistributedAdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.AdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.AdjustmentAmount
.
Type | Description |
---|---|
void |
Set CartItem.TotalPromoAdjustmentAmount
.
Type | Description |
---|---|
void |
Get CartItem.TotalPromoAdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.TotalTaxAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.TotalLineAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.TotalLineAmount
.
Type | Description |
---|---|
void |
Get CartItem.TotalAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.ItemizedAdjustmentTaxAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.DistributedAdjustmentTaxAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.AdjustmentTaxAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.AdjustmentTaxAmount
.
Type | Description |
---|---|
void |
Get CartItem.TotalPriceAfterAllAdjustments
.
Type | Description |
---|---|
Decimal |
Set CartItem.TotalPriceAfterAllAdjustments
.
Type | Description |
---|---|
void |
Get CartItem.UnitAdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.UnitAdjustmentAmount
.
Type | Description |
---|---|
void |
Get CartItem.TotalAdjustmentAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.TotalAdjustmentAmount
.
Type | Description |
---|---|
void |
Get all CartExtension.CartItemPriceAdjustment objects associated with the current CartItem
. Specifically, fetch CartItemPriceAdjustment
instances where the CartItemPriceAdjustment.CartItem
matches the ID of the current CartItem
.
Type | Description |
---|---|
CartItemPriceAdjustmentList | CartExtension.CartItemPriceAdjustmentList |
Get all CartExtension.CartTax objects associated with the current CartItem
. Specifically, fetch CartTax
instances where the CartTax.CartItem
matches the ID of the current CartItem
. This method doesn't include tax adjustments that are related to item price adjustments for the CartItem
, such as CartTax
related to a CartItemPriceAdjustment
.
Type | Description |
---|---|
CartTaxList | CartExtension.CartTaxList |
Get CartItem.TotalLineNetAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.TotalLineGrossAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.ProductSellingModelId
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
ID |
Get CartItem.SubscriptionTerm
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
Integer |
Get CartItem.BillingFrequency
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
BillingFrequencyEnum | CartExtension.BillingFrequencyEnum |
Set CartItem.BillingFrequency
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.PeriodBoundary
.
Type | Description |
---|---|
PeriodBoundaryEnum | CartExtension.PeriodBoundaryEnum |
Get CartItem.PeriodBoundaryDay
.
Type | Description |
---|---|
Integer | Integer |
Get CartItem.PeriodBoundaryStartMonth
.
Type | Description |
---|---|
Integer | Integer |
Get CartItem.PricingTermCount
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
Decimal |
Set CartItem.PricingTermCount
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.PricebookEntryId
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
ID |
Set CartItem.PricebookEntryId
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.ProrationPolicyId
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
ID |
Set CartItem.ProrationPolicyId
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.SellingModelType
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
SellingModelType | CartExtension.SellingModelType |
Set CartItem.SellingModelType
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.UnitPriceAfterAdjustments
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
Decimal |
Set CartItem.UnitPriceAfterAdjustments
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.NetUnitPriceAfterAdjustments
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
Decimal |
Set CartItem.NetUnitPriceAfterAdjustments
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.FirstPymtPriceAfterAdjustments
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
Decimal |
Set CartItem.FirstPymtPriceAfterAdjustments
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
void |
Get CartItem.FirstPymtTax
. This method is only available for organizations that have Commerce Subscription Plus enabled.
Type | Description |
---|---|
Decimal |
Set CartItem.FirstPymtTax
.
Type | Description |
---|---|
void |
Get CartItem.TotalFirstPymtPrice
.
Type | Description |
---|---|
Decimal |
Get CartItem.TotalFirstPymtAdjAmount
.
Type | Description |
---|---|
Decimal |
Get CartItem.TotalLineFirstPymtTaxAmount
.
Type | Description |
---|---|
Decimal |
Set CartItem.ProductRelatedComponentId
.
Type | Description |
---|---|
void |
Get CartItem.ProductRelatedComponentId
.
Type | Description |
---|---|
ID |
Set CartItem.ProductClass
.
Type | Description |
---|---|
void |
Get CartItem.ProductClass
.
Type | Description |
---|---|
ProductClass | CartExtension.ProductClass |
Set CartItem.StockCheckMethod
Type | Description |
---|---|
void |
Get CartItem.StockCheckMethod
.
Type | Description |
---|---|
StockCheckMethod | CartExtension.StockCheckMethod |
Set CartItem.PerUnitWeight
.
Type | Description |
---|---|
void |
Get CartItem.getPerUnitWeight
.
Type | Description |
---|---|
Decimal | Decimal |
Set CartItem.WeightUnit
.
Type | Description |
---|---|
void |
Get CartItem.getWeightUnit
.
Type | Description |
---|---|
String | getWeightUnit |
Get CartItem.getTotalWeight
.
Type | Description |
---|---|
Decimal | Decimal |
Set CartItem.TaxTreatmentId
.
Type | Description |
---|---|
void |
Get CartItem.TaxTreatmentId
.
Type | Description |
---|---|
ID | TaxTreatmentId |
Get CartItem.IsShippingChargeNotApplicable
.
Type | Description |
---|---|
Boolean | Boolean |
Set CartItem.IsShippingChargeNotApplicable
.
Type | Description |
---|---|
void |
Get Id
.
Type | Description |
---|---|
ID |
Get System Field CreatedDate
.
Type | Description |
---|---|
Datetime |
Get System Field LastModifiedDate
.
Type | Description |
---|---|
Datetime |
Get System Field CreatedById
.
Type | Description |
---|---|
ID |
Get System Field LastModifiedById
.
Type | Description |
---|---|
ID |
Get value of the given custom field (needs to be api name)
Type | Description |
---|---|
Object |
Set the value of the given custom field (needs to be api name)
Type | Description |
---|---|
void |