Method | Description | Returns |
---|---|---|
getItemPrice() | Returns the price for a single item | string |
getCurrency() | Get the currency of the item. It prefers the checkout/order currency over the cart currency. | Currency |
getAmountAsMoney() | Get the amount of the item as a Money object. | Money |
getUnitPriceAsMoney() | Get the unit price of the item as a Money object. | Money |
getDiscountAsMoney() | Get the discount of the item as a Money object. | Money |
getId() | int | |
getProductCode() | string | |
getName() | string | |
getQuantity() | Quantity of the item. Integer positive (not 0) number. | int |
getAmount() | string | |
getTax() | string | |
getDiscount() | string | |
getAttributes() | string | |
isAvailable() | If an item is available, i.e. its product still available or the item is not expired. | bool |
getCreated() | Date the record was created. | DateTime |
getModified() | Last modification date for the record. | DateTime |
getCart() | Cart | |
getOrder() | BaseOrder | |
getProduct() | BaseProduct | |
getMessages() | Collection (Message) | |
getDiscountLogs() | Gets discount logs associated with an item. Logs are changing only on the checkout operations, not inside the cart. | Collection (Log) |
isNewRecord() | Check if the record is a new record | bool |
isHierarchicalModel() | Check whether a model is a hierarchical model, i.e. can have children | bool |
isVersionedModel() | Check whether a model is versioned | bool |
Carts\Models\Frontend\Item
Item that appears in the Cart for the first time and then can go to the Order