You are here

function sheetnode_plugin_style::options_form in Sheetnode 6

Same name and namespace in other branches
  1. 7.2 views/sheetnode_plugin_style.inc \sheetnode_plugin_style::options_form()
  2. 7 views/sheetnode_plugin_style.inc \sheetnode_plugin_style::options_form()
1 call to sheetnode_plugin_style::options_form()
sheetnode_feed_plugin_style::options_form in views/sheetnode_plugin_style.inc
1 method overrides sheetnode_plugin_style::options_form()
sheetnode_feed_plugin_style::options_form in views/sheetnode_plugin_style.inc

File

views/sheetnode_plugin_style.inc, line 17

Class

sheetnode_plugin_style

Code

function options_form(&$form, &$form_values) {
  parent::options_form($form, $form_values);
  $form['expansion'] = array(
    '#type' => 'radios',
    '#title' => t('Expansion of results'),
    '#description' => t('You can specify whether view results should be expanded horizontally or vertically.'),
    '#options' => array(
      SHEETNODE_EXPANSION_VERTICAL => t('Consecutive rows'),
      SHEETNODE_EXPANSION_HORIZONTAL => t('Consecutive columns'),
    ),
    '#default_value' => $this->options['expansion'],
    '#weight' => 97,
  );
  $form['template'] = array(
    '#type' => 'checkbox',
    '#title' => t('Use template'),
    '#description' => t('Check this box to use the spreadsheet below as template for your view.
                           To place view results in the template, use the following syntax in the cells:
                           <ul>
                           <li><code>${field_label}</code> to indicate that this cell and subsequent ones should be filled with values of this field.</li>
                           <li><code>${FUNCTION(@field_label@, $field_label$, @cell_reference@, ...)}</code> to indicate that this cell and subsequent ones should be filled with a calculation.
                           <code>@field_label@</code> are replaced with the corresponding cell references, and <code>$field_label$</code> are replaced with actual field values.</li>
                           <li><code>$[FUNCTION(@field_label@, @cell_reference@, ...)]</code> to indicate that a calculation should be placed in this cell.
                           <code>@field_label@</code> are replaced with the corresponding cell ranges.</li>
                           </ul>'),
    '#default_value' => $this->options['template'],
    '#weight' => 98,
  );
  $form['sheetview'] = array(
    '#value' => $this
      ->render_ajax($this->options['sheetsave'], 'edit-style-options-sheetsave'),
    '#weight' => 99,
  );
  $form['sheetsave'] = array(
    '#type' => 'hidden',
  );
}