Model
Item
Magento\Sales\Model\Order\Invoice\Item
What it does
This class represents a single item line in a Magento 2 invoice.
Developers use it when creating invoices, capturing payments, or canceling invoices to track quantities invoiced, prices, taxes, and discounts for each product.
It maintains the relationship between invoice items and their corresponding order items, automatically updating invoiced quantities and amounts on the order.
Public Methods
- setInvoice()
- getInvoice()
- setOrderItem()
- getOrderItem()
- setQty()
- register()
- cancel()
- calcRowTotal()
- isLast()
- getAdditionalData()
- getBaseCost()
- getBaseDiscountAmount()
- getBaseDiscountTaxCompensationAmount()
- getBasePrice()
- getBasePriceInclTax()
- getBaseRowTotal()
- getBaseRowTotalInclTax()
- getBaseTaxAmount()
- getDescription()
- getDiscountAmount()
- getDiscountTaxCompensationAmount()
- getName()
- getOrderItemId()
- getParentId()
- getPrice()
- getPriceInclTax()
- getProductId()
- getQty()
- getRowTotal()
- getRowTotalInclTax()
- getSku()
- getTaxAmount()
- setParentId()
- setBasePrice()
- setTaxAmount()
- setBaseRowTotal()
- setDiscountAmount()
- setRowTotal()
- setBaseDiscountAmount()
- setPriceInclTax()
- setBaseTaxAmount()
- setBasePriceInclTax()
- setBaseCost()
- setPrice()
- setBaseRowTotalInclTax()
- setRowTotalInclTax()
- setProductId()
- setOrderItemId()
- setAdditionalData()
- setDescription()
- setSku()
- setName()
- setDiscountTaxCompensationAmount()
- setBaseDiscountTaxCompensationAmount()
- getExtensionAttributes()
- setExtensionAttributes()