You are here

public function ModuleEnabled::summary in Varbase Total Control Dashboard 8.6

Same name and namespace in other branches
  1. 8 src/Plugin/Condition/ModuleEnabled.php \Drupal\varbase_total_control\Plugin\Condition\ModuleEnabled::summary()
  2. 8.5 src/Plugin/Condition/ModuleEnabled.php \Drupal\varbase_total_control\Plugin\Condition\ModuleEnabled::summary()
  3. 9.0.x src/Plugin/Condition/ModuleEnabled.php \Drupal\varbase_total_control\Plugin\Condition\ModuleEnabled::summary()

Provides a human readable summary of the condition's configuration.

Overrides ConditionInterface::summary

File

src/Plugin/Condition/ModuleEnabled.php, line 51

Class

ModuleEnabled
Provides a 'Module' condition.

Namespace

Drupal\varbase_total_control\Plugin\Condition

Code

public function summary() {

  // Use the role labels. They will be sanitized below.
  $module = $this->configuration['module'];
  if (!empty($this->configuration['negate'])) {
    return $this
      ->t('If the module <b>@module</b> is not installed.', [
      '@module' => $module,
    ]);
  }
  else {
    return $this
      ->t('If the module <b>@module</b> is installed.', [
      '@module' => $module,
    ]);
  }
}