Symbiote\MultiValueField\Fields\MultiValueCheckboxField
A checkboxset that uses a multivalue field for key / val pairs
- Author: marcus@symbiote.com.au
- License: BSD License http://silverstripe.org/bsd-license/
Synopsis
class MultiValueCheckboxField
extends CheckboxSetField
{
- // members
- protected boolean $disabled = false;
- protected array $defaultItems = ;
- protected boolean $storeKeys = false;
- // methods
- public void Field()
- public void setDisabled()
- public void setDefaultItems()
- public void setStoreKeys()
- public Array getDefaultItems()
- public void saveInto()
- public string dataValue()
- public void performDisabledTransformation()
- public ReadonlyField performReadonlyTransformation()
- public void ExtraOptions()
Hierarchy
Extends
- SilverStripe\Forms\CheckboxSetField
Tasks
Line | Task |
---|---|
41+ | Explain different source data that can be used with this field, e.g. SQLMap, DataObjectSet or an array. |
41+ | Should use CheckboxField FieldHolder rather than constructing own markup. |
Members
protected
- $defaultItems — array
- $disabled
- $storeKeys
—
boolean
Do we store keys + values or just the values?
Methods
public
- ExtraOptions()
- Field()
- dataValue() — Return the CheckboxSetField value as a string selected item keys.
- getDefaultItems()
- performDisabledTransformation()
- performReadonlyTransformation() — Transforms the source data for this CheckboxSetField into a comma separated list of values.
- saveInto() — Save the current value of this CheckboxSetField into a DataObject.
- setDefaultItems() — Default selections, regardless of the {@link setValue()} settings.
- setDisabled()
- setStoreKeys() — Do we store keys and values?