You are here

public function Stid::titleQuery in Support Ticketing System 8

Override the behavior of title(). Get the title of the support ticket.

Overrides NumericArgument::titleQuery

File

modules/support_ticket/src/Plugin/views/argument/Stid.php, line 60
Contains \Drupal\support_ticket\Plugin\views\argument\Stid.

Class

Stid
Argument handler to accept a support ticket id.

Namespace

Drupal\support_ticket\Plugin\views\argument

Code

public function titleQuery() {
  $titles = array();
  $support_tickets = $this->supportTicketStorage
    ->loadMultiple($this->value);
  foreach ($support_tickets as $support_ticket) {
    $titles[] = SafeMarkup::checkPlain($support_ticket
      ->label());
  }
  return $titles;
}