You are here

function Table::attach_to in Views PDF 8

Attach this view to another display as a feed.

Provide basic functionality for all export style views like attaching a feed image link.

File

src/Plugin/views/style/Table.php, line 344

Class

Table
Style plugin to render each item as a row in a table.

Namespace

Drupal\tardis\Plugin\views\style

Code

function attach_to($display_id, $path, $title) {
  $display = $this->view->display[$display_id]->handler;
  $url_options = array();
  $input = $this->view
    ->get_exposed_input();
  if ($input) {
    $url_options['query'] = $input;
  }
  if (empty($this->view->feed_icon)) {
    $this->view->feed_icon = '';
  }
  $this->view->feed_icon .= theme('views_pdf_icon', array(
    'path' => $this->view
      ->get_url(NULL, $path),
    'title' => $title,
    'options' => $url_options,
  ));
}