You are here

public function PriceListItem::getPurchasedEntity in Commerce Pricelist 8

Gets the purchased entity.

Return value

\Drupal\commerce\PurchasableEntityInterface|null The purchased entity, or NULL.

Overrides PriceListItemInterface::getPurchasedEntity

File

src/Entity/PriceListItem.php, line 173

Class

PriceListItem
Defines the price list item entity.

Namespace

Drupal\commerce_pricelist\Entity

Code

public function getPurchasedEntity() {
  return $this
    ->getTranslatedReferencedEntity('purchased_entity');
}