You are here

public function QueryActivity::getActivityEventField in Activity 8

Get row for the field needed.

Parameters

string $eventId: The action name.

string $field: The field needed.

File

src/QueryActivity.php, line 61

Class

QueryActivity
Provides queries for activity.

Namespace

Drupal\activity

Code

public function getActivityEventField($eventId, $field) {
  $query = $this->database
    ->select('activity_events', 'act')
    ->fields('act', [
    $field,
  ])
    ->condition('event_id', $eventId)
    ->execute()
    ->fetchAll();
  return $query;
}