You are here

public function TransactionOperation::calculateDependencies in Transaction 8

Calculates dependencies and stores them in the dependency property.

Return value

$this

Overrides ConfigEntityBase::calculateDependencies

See also

\Drupal\Core\Config\Entity\ConfigDependencyManager

File

src/Entity/TransactionOperation.php, line 148

Class

TransactionOperation
Transaction operations provide templates that describe transactions.

Namespace

Drupal\transaction\Entity

Code

public function calculateDependencies() {
  parent::calculateDependencies();
  $transaction_type = TransactionType::load($this
    ->getTransactionTypeId());
  $this
    ->addDependency($transaction_type
    ->getConfigDependencyKey(), $transaction_type
    ->getConfigDependencyName());
  return $this;
}