You are here

class LegacySetUnpublishingDate in Scheduler 2.x

Provides a 'Set date for scheduled unpublishing' action just for nodes.

Plugin annotation


@RulesAction(
  id = "scheduler_set_unpublishing_date_action",
  entity_type_id = "node",
  label = @Translation("Set date for unpublishing a content item"),
  category = @Translation("Content (Scheduler)"),
  context_definitions = {
    "node" = @ContextDefinition("entity:node",
      label = @Translation("Node for scheduling"),
      description = @Translation("The node which is to have a scheduled unpublishing date set"),
      assignment_restriction = "selector",
    ),
    "date" = @ContextDefinition("timestamp",
      label = @Translation("The date for unpublishing"),
      description = @Translation("The date when Scheduler will unpublish the node"),
    )
  }
)

Hierarchy

Expanded class hierarchy of LegacySetUnpublishingDate

File

scheduler_rules_integration/src/Plugin/RulesAction/Legacy/LegacySetUnpublishingDate.php, line 28

Namespace

Drupal\scheduler_rules_integration\Plugin\RulesAction\Legacy
View source
class LegacySetUnpublishingDate extends SetUnpublishingDate {

}

Members

Namesort descending Modifiers Type Description Overrides
SchedulerRulesActionBase::$entityTypeId protected property The entity type id.
SchedulerRulesActionBase::create public static function
SchedulerRulesActionBase::notEnabledWarning public function Gives a warning when an entity is not enabled for Scheduler.
SchedulerRulesActionBase::__construct public function Constructs a SchedulerRulesActionBase object.
SetUnpublishingDate::doExecute public function Set the unpublish_on date on the entity.