You are here

function views_parity_row_views_plugin_row_entity_view::options_form_summary_options in Views Parity Row 7

Return the main options, which are shown in the summary title.

File

views/views_parity_row_views_plugin_row_entity_view.inc, line 18
Contains the Views Parity Row row style plugin for entities.

Class

views_parity_row_views_plugin_row_entity_view
Plugin which performs a entity_view on the resulting object.

Code

function options_form_summary_options() {
  $entity_info = entity_get_info($this->entity_type);
  $options = array();
  if (!empty($entity_info['view modes'])) {
    foreach ($entity_info['view modes'] as $mode => $settings) {
      $options[$mode] = $settings['label'];
    }
  }
  if (empty($options)) {
    $options = array(
      'teaser' => t('Teaser'),
      'full' => t('Full content'),
    );
  }
  return $options;
}