You are here

function views_plugin_display::accept_attachments in Views (for Drupal 7) 6.3

Same name and namespace in other branches
  1. 6.2 plugins/views_plugin_display.inc \views_plugin_display::accept_attachments()
  2. 7.3 plugins/views_plugin_display.inc \views_plugin_display::accept_attachments()

Can this display accept attachments?

File

plugins/views_plugin_display.inc, line 325
Contains the base display plugin.

Class

views_plugin_display
The default display plugin handler. Display plugins handle options and basic mechanisms for different output methods.

Code

function accept_attachments() {
  if (empty($this->definition['accept attachments'])) {
    return FALSE;
  }
  if (!empty($this->view->argument) && $this
    ->get_option('hide_attachment_summary')) {
    foreach ($this->view->argument as $argument_id => $argument) {
      if ($argument
        ->needs_style_plugin() && empty($argument->argument_validated)) {
        return FALSE;
      }
    }
  }
  return TRUE;
}