You are here

public function EmailActivitySend::create in Open Social 8.2

Same name and namespace in other branches
  1. 8.9 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  2. 8 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  3. 8.3 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  4. 8.4 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  5. 8.5 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  6. 8.6 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  7. 8.7 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  8. 8.8 modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  9. 10.3.x modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  10. 10.0.x modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  11. 10.1.x modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()
  12. 10.2.x modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php \Drupal\activity_send_email\Plugin\ActivitySend\EmailActivitySend::create()

Create a new item in queue on the action with some logic behind it.

Overrides ActivitySendInterface::create

File

modules/custom/activity_send/modules/activity_send_email/src/Plugin/ActivitySend/EmailActivitySend.php, line 20

Class

EmailActivitySend
Provides a 'EmailActivitySend' activity action.

Namespace

Drupal\activity_send_email\Plugin\ActivitySend

Code

public function create($entity) {
  $data['entity_id'] = $entity
    ->id();
  $queue = \Drupal::queue('activity_send_email_worker');
  $queue
    ->createItem($data);
}