public function Product::getVariations in Commerce Core 8.2
Gets the variations.
Return value
\Drupal\commerce_product\Entity\ProductVariationInterface[] The variations.
Overrides ProductInterface::getVariations
1 call to Product::getVariations()
- Product::getDefaultVariation in modules/
product/ src/ Entity/ Product.php - Gets the default variation.
File
- modules/
product/ src/ Entity/ Product.php, line 174
Class
- Product
- Defines the product entity class.
Namespace
Drupal\commerce_product\EntityCode
public function getVariations() {
return $this
->getTranslatedReferencedEntities('variations');
}