Skip to content

Instantly share code, notes, and snippets.

@jhedstrom
Created January 30, 2015 17:21
Show Gist options
  • Save jhedstrom/6107a6f15c5f1e84425c to your computer and use it in GitHub Desktop.
Save jhedstrom/6107a6f15c5f1e84425c to your computer and use it in GitHub Desktop.
<?php
/**
* Provide actual overridden view config.
*/
protected function getOverriddenView() {
$view = array(
'display' => array(
'default' => array(
'display_options' => array(
'sorts' => array(
// We need to redeclare other sorts here too, since the order matters!!.
'sticky' => array(),
'weight' => array(
'id' => 'weight',
'table' => 'taxonomy_index',
'field' => 'weight',
'relationship' => 'none',
'group_type' => 'group',
'admin_label' => '',
'order' => 'ASC',
'exposed' => false,
'expose' => array(
'label' => '',
),
'plugin_id' => 'standard',
),
'created' => array(
'id' => 'created',
'table' => 'taxonomy_index',
'field' => 'created',
'order' => 'DESC',
'plugin_id' => 'date',
'relationship' => 'none',
'group_type' => 'group',
'admin_label' => '',
'exposed' => false,
'expose' => array(
'label' => '',
),
'granularity' => 'second',
),
),
),
),
),
);
return $view;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment