public function ViewExecutable::attachDisplays in Views (for Drupal 7) 8.3
Run attachment displays for the view.
1 call to ViewExecutable::attachDisplays()
- ViewExecutable::build in lib/
Drupal/ views/ ViewExecutable.php - Build the query for the view.
File
- lib/
Drupal/ views/ ViewExecutable.php, line 1460 - Definition of Drupal\views\ViewExecutable.
Class
- ViewExecutable
- An object to contain all of the data to generate a view, plus the member functions to build the view query, execute the query and render the output.
Namespace
Drupal\viewsCode
public function attachDisplays() {
if (!empty($this->is_attachment)) {
return;
}
if (!$this->display_handler
->acceptAttachments()) {
return;
}
$this->is_attachment = TRUE;
// Give other displays an opportunity to attach to the view.
foreach ($this->displayHandlers as $id => $display) {
if (!empty($this->displayHandlers[$id])) {
$this->displayHandlers[$id]
->attachTo($this->current_display);
}
}
$this->is_attachment = FALSE;
}