public function ProductVariationStorageInterface::loadBySku in Commerce Core 8.2
Loads the product variation for the given SKU.
Parameters
string $sku: The SKU.
Return value
\Drupal\commerce_product\Entity\ProductVariationInterface|null The product variation, or NULL if not found.
1 method overrides ProductVariationStorageInterface::loadBySku()
- ProductVariationStorage::loadBySku in modules/
product/ src/ ProductVariationStorage.php - Loads the product variation for the given SKU.
File
- modules/
product/ src/ ProductVariationStorageInterface.php, line 22
Class
- ProductVariationStorageInterface
- Defines the interface for product variation storage.
Namespace
Drupal\commerce_productCode
public function loadBySku($sku);