You are here

public function CommerceAutoSkuManager::hasOptionalAutoSku in Commerce AutoSKU 8.2

Determines if the entity bundle has an optional automatic label.

Optional means that if the label is empty, it will be automatically generated.

Return value

bool True if the entity bundle has an optional automatic label.

Overrides CommerceAutoSkuManagerInterface::hasOptionalAutoSku

1 call to CommerceAutoSkuManager::hasOptionalAutoSku()
CommerceAutoSkuManager::autoSkuNeeded in src/CommerceAutoSkuManager.php
Returns whether the automatic label has to be set.

File

src/CommerceAutoSkuManager.php, line 160
Contains \Drupal\commerce_autosku\AutoEntityLabelManager.

Class

CommerceAutoSkuManager

Namespace

Drupal\commerce_autosku

Code

public function hasOptionalAutoSku() {
  return $this
    ->getConfig('mode') == self::OPTIONAL;
}