QueueStorageEntitySendActivityCondition.php in Open Social 8.9
Same filename and directory in other branches
- 8.8 modules/custom/social_queue_storage/src/Plugin/ActivityEntityCondition/QueueStorageEntitySendActivityCondition.php
- 10.3.x modules/custom/social_queue_storage/src/Plugin/ActivityEntityCondition/QueueStorageEntitySendActivityCondition.php
- 10.0.x modules/custom/social_queue_storage/src/Plugin/ActivityEntityCondition/QueueStorageEntitySendActivityCondition.php
- 10.1.x modules/custom/social_queue_storage/src/Plugin/ActivityEntityCondition/QueueStorageEntitySendActivityCondition.php
- 10.2.x modules/custom/social_queue_storage/src/Plugin/ActivityEntityCondition/QueueStorageEntitySendActivityCondition.php
File
modules/custom/social_queue_storage/src/Plugin/ActivityEntityCondition/QueueStorageEntitySendActivityCondition.phpView source
<?php
namespace Drupal\social_queue_storage\Plugin\ActivityEntityCondition;
use Drupal\activity_creator\Plugin\ActivityEntityConditionBase;
/**
* Provides a 'QueueStorageEntitySendActivityAction` activity action.
*
* @ActivityEntityCondition(
* id = "queue_store_entity_send_activity_condition",
* label = @Translation("Queue Store Entity has is finished status."),
* entities = {"queue_storage_entity" = {}}
* )
*/
class QueueStorageEntitySendActivityCondition extends ActivityEntityConditionBase {
/**
* {@inheritdoc}
*/
public function isValidEntityCondition($entity) {
/** @var \Drupal\social_queue_storage\Entity\QueueStorageEntity $entity */
if ($entity
->getEntityTypeId() === 'queue_storage_entity') {
return $entity
->isFinished();
}
return FALSE;
}
}
Classes
Name | Description |
---|---|
QueueStorageEntitySendActivityCondition | Provides a 'QueueStorageEntitySendActivityAction` activity action. |