You are here

function _spaces_core_views_taxonomy in Spaces 5

Same name and namespace in other branches
  1. 5.2 spaces_core/spaces_core.module \_spaces_core_views_taxonomy()
1 string reference to '_spaces_core_views_taxonomy'
spaces_core_views_default_views in spaces_core/spaces_core.module
Implementation of hook_default_views

File

spaces_core/spaces_core.module, line 919

Code

function _spaces_core_views_taxonomy() {
  $view = new stdClass();
  $view->name = 'spaces_taxonomy';
  $view->description = t('Spaces taxonomy override.');
  $view->access = $view->field = $view->exposed_filter = array();
  $view->page = TRUE;
  $view->page_empty = '<p>' . t('No entries found.') . '</p>';
  $view->page_empty_format = '2';
  $view->page_type = 'table';
  $view->use_pager = TRUE;
  $view->nodes_per_page = '20';
  $view->field = array(
    array(
      'tablename' => 'node',
      'field' => 'title',
      'label' => 'Title',
      'handler' => 'views_handler_field_nodelink',
      'sortable' => '1',
      'options' => 'link',
    ),
    array(
      'tablename' => 'node',
      'field' => 'created',
      'label' => 'Date',
      'handler' => 'views_handler_field_date_small',
      'sortable' => '1',
      'defaultsort' => 'DESC',
    ),
    array(
      'tablename' => 'node',
      'field' => 'type',
      'label' => 'Type',
      'sortable' => '1',
    ),
  );
  $view->sort = array();
  $view->argument = array(
    array(
      'type' => 'gid',
      'argdefault' => '2',
    ),
    array(
      'type' => 'taxid',
      'argdefault' => '1',
      'options' => '0',
      'wildcard' => '',
      'wildcard_substitution' => '',
    ),
  );
  $view->filter = array(
    array(
      'tablename' => 'node',
      'field' => 'status',
      'operator' => '=',
      'options' => '',
      'value' => '1',
    ),
  );
  $view->requires = array(
    node,
  );
  return $view;
}