You are here

public function OrderItem::getQuantity in Commerce Core 8.2

Gets the order item quantity.

Return value

string The order item quantity

Overrides OrderItemInterface::getQuantity

3 calls to OrderItem::getQuantity()
OrderItem::getAdjustedTotalPrice in modules/order/src/Entity/OrderItem.php
Gets the adjusted order item total price.
OrderItem::getAdjustedUnitPrice in modules/order/src/Entity/OrderItem.php
Gets the adjusted order item unit price.
OrderItem::recalculateTotalPrice in modules/order/src/Entity/OrderItem.php
Recalculates the order item total price.

File

modules/order/src/Entity/OrderItem.php, line 106

Class

OrderItem
Defines the order item entity class.

Namespace

Drupal\commerce_order\Entity

Code

public function getQuantity() {
  return (string) $this
    ->get('quantity')->value;
}