You are here

function slickgrid_views_plugin::option_definition in Slickgrid 7

Same name and namespace in other branches
  1. 6 slickgrid_views_plugin.inc \slickgrid_views_plugin::option_definition()
  2. 7.2 includes/slickgrid_views_plugin.inc \slickgrid_views_plugin::option_definition()

Set default options

Overrides views_plugin_style::option_definition

File

includes/slickgrid_views_plugin.inc, line 21

Class

slickgrid_views_plugin
Extending the view_plugin_style class to provide a slickgrid style.

Code

function option_definition() {
  $options = parent::option_definition();

  // Grouping
  $options['grouping_field'] = array(
    'default' => NULL,
  );
  $options['collapse_groups_by_default'] = array(
    'default' => FALSE,
  );

  // Settings
  $options['collapsible_taxonomy_field'] = array(
    'default' => NULL,
  );

  // maps to slickgrid option enableColumnResize
  $options['enableColumnResize'] = array(
    'default' => TRUE,
  );

  // maps to slickgrid option enableColumnReorder
  $options['enableColumnReorder'] = array(
    'default' => TRUE,
  );
  $options['select_columns'] = array(
    'default' => TRUE,
  );

  // maps to slickgrid option asyncEditorLoading
  $options['asyncEditorLoading'] = array(
    'default' => TRUE,
  );

  // maps to slickgrid option forceFitColumns
  $options['forceFitColumns'] = array(
    'default' => false,
  );
  $options['pager'] = array(
    'default' => false,
  );

  // maps to slickgrid option headerHeight
  $options['headerHeight'] = array(
    'default' => 42,
  );
  $options['viewport_height'] = array(
    'default' => 500,
  );

  // maps to slickgrid option rowHeight
  $options['rowHeight'] = array(
    'default' => 30,
  );

  // Editing
  $options['row_selection_checkbox'] = array(
    'default' => false,
  );

  // If row selection checkbox is enabled, the following values are available
  $options['multi_edit'] = array(
    'default' => false,
  );
  $options['delete'] = array(
    'default' => false,
  );
  $options['clone'] = array(
    'default' => false,
  );
  $options['export_selected_rows'] = array(
    'default' => false,
  );

  // Undo editing
  $options['undo'] = array(
    'default' => false,
  );

  // Node add button
  $options['add'] = array(
    'default' => false,
  );

  // maps to slickgrid option autoEdit
  $options['autoEdit'] = array(
    'default' => FALSE,
  );
  return $options;
}