function sheetnode_plugin_style::options_form in Sheetnode 7.2
Same name and namespace in other branches
- 6 views/sheetnode_plugin_style.inc \sheetnode_plugin_style::options_form()
- 7 views/sheetnode_plugin_style.inc \sheetnode_plugin_style::options_form()
Set plugin style option form.
Overrides views_plugin_style::options_form
1 call to sheetnode_plugin_style::options_form()
- sheetnode_feed_plugin_style::options_form in views/
sheetnode_plugin_style.inc - Set sheetnod feed option form.
1 method overrides sheetnode_plugin_style::options_form()
- sheetnode_feed_plugin_style::options_form in views/
sheetnode_plugin_style.inc - Set sheetnod feed option form.
File
- views/
sheetnode_plugin_style.inc, line 31
Class
- sheetnode_plugin_style
- Extentions for 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['use_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['use_template'],
'#weight' => 98,
);
$id = 'edit-style-options-template';
$form['template'] = array(
'#type' => 'hidden',
'#attributes' => array(
'id' => $id,
),
'#weight' => 99,
);
$this
->render_inject($this->options['template'], $id, $form['template'], '#prefix');
}