1 views_ui_base_views_wizard.php protected ViewsUiBaseViewsWizard::page_display_options($form, $form_state)

File

core/modules/views_ui/wizards/views_ui_base_views_wizard.php, line 787
Provides the interface and base class for Views Wizard plugins.

Class

ViewsUiBaseViewsWizard
A very generic Views Wizard class - can be constructed for any base table.

Code

protected function page_display_options($form, $form_state) {
  $display_options = array();
  $page = $form_state['values']['page'];
  $display_options['title'] = $page['title'];
  $display_options['path'] = $page['path'];
  $display_options['style_plugin'] = $page['style']['style_plugin'];
  // Not every style plugin supports row style plugins.
  $display_options['row_plugin'] = isset($page['style']['row_plugin']) ? $page['style']['row_plugin'] : 'fields';
  if (empty($page['items_per_page'])) {
    $display_options['pager']['type'] = 'none';
  }
  elseif (!empty($page['pager'])) {
    $display_options['pager']['type'] = 'full';
  }
  else {
    $display_options['pager']['type'] = 'some';
  }
  $display_options['pager']['options']['items_per_page'] = $page['items_per_page'];
  if (!empty($page['link'])) {
    $display_options['menu']['type'] = 'normal';
    $display_options['menu']['title'] = $page['link_properties']['title'];
    $display_options['menu']['name'] = $page['link_properties']['menu_name'];
  }
  return $display_options;
}