You are here

public function Instances::revertInstance in Smart Date 3.x

Same name and namespace in other branches
  1. 8.2 modules/smart_date_recur/src/Controller/Instances.php \Drupal\smart_date_recur\Controller\Instances::revertInstance()
  2. 3.0.x modules/smart_date_recur/src/Controller/Instances.php \Drupal\smart_date_recur\Controller\Instances::revertInstance()
  3. 3.1.x modules/smart_date_recur/src/Controller/Instances.php \Drupal\smart_date_recur\Controller\Instances::revertInstance()
  4. 3.2.x modules/smart_date_recur/src/Controller/Instances.php \Drupal\smart_date_recur\Controller\Instances::revertInstance()
  5. 3.3.x modules/smart_date_recur/src/Controller/Instances.php \Drupal\smart_date_recur\Controller\Instances::revertInstance()
  6. 3.4.x modules/smart_date_recur/src/Controller/Instances.php \Drupal\smart_date_recur\Controller\Instances::revertInstance()

Revert instance by deleting the override.

Parameters

\Drupal\smart_date_recur\Entity\SmartDateOverride $entity: The override entity to remove.

Throws

\Drupal\Core\Entity\EntityStorageException

1 call to Instances::revertInstance()
Instances::revertAjax in modules/smart_date_recur/src/Controller/Instances.php
Reverting a rule instance in an Ajax confirm dialog.

File

modules/smart_date_recur/src/Controller/Instances.php, line 560

Class

Instances
Provides listings of instances (with overrides) for a specified rule.

Namespace

Drupal\smart_date_recur\Controller

Code

public function revertInstance(SmartDateOverride $entity) {
  $entity
    ->delete();
}