◆ __construct()
◆ createDataFieldEntry()
| static createDataFieldEntry |
( |
DataField |
$datafield, |
|
|
|
$rangeID = '', |
|
|
|
$value = null |
|
) |
| |
|
static |
Factory method that returns the appropriate datafield object for the given parameters.
- Parameters
-
| DataField | $datafield | Underlying structure |
| String | $rangeID | Range id |
| mixed | $value | Value of the entry |
- Returns
- DataFieldEntry instance of appropriate type
◆ getDataFieldEntries()
| static getDataFieldEntries |
( |
|
$range_id, |
|
|
|
$object_type = '', |
|
|
|
$object_class_hint = '' |
|
) |
| |
|
static |
Enter description here...
- Parameters
-
| unknown_type | $range_id | |
| unknown_type | $object_type | |
| unknown_type | $object_class_hint | |
- Returns
- unknown
◆ getDescription()
Returns the description of this datafield
- Returns
- String containing the description
◆ getDisplayValue()
| getDisplayValue |
( |
|
$entities = true | ) |
|
◆ getHTML()
| getHTML |
( |
|
$name = '', |
|
|
|
$variables = array() |
|
) |
| |
Returns the according input elements as html for this datafield
- Parameters
-
| String | $name | Name prefix of the associated input |
| Array | $variables | Additional variables |
- Returns
- String containing the required html
Reimplemented in DataFieldComboEntry, DataFieldDateEntry, DataFieldPhoneEntry, DataFieldRadioEntry, DataFieldSelectboxEntry, DataFieldSelectboxMultipleEntry, DataFieldTextareai18nEntry, DataFieldTextlineEntry, DataFieldTextlinei18nEntry, DataFieldTextmarkupEntry, DataFieldTextmarkupi18nEntry, and DataFieldTimeEntry.
◆ getId()
Returns the id of the datafield
- Returns
- String containing the id
◆ getName()
Returns the name of the datafield
- Returns
- String containing the name
◆ getPermsDescription()
Returns a human readable string describing the view permissions
- Returns
- String containing the descriptons of the view permissions
◆ getRangeID()
Returns the range id
- Returns
- String containing the range id
◆ getSecondRangeID()
Returns the secondary range id
- Returns
- String containing the secondary range id
◆ getSupportedTypes()
| static getSupportedTypes |
( |
| ) |
|
|
static |
Returns all supported datafield types
- Returns
- array of supported types
◆ getType()
Returns the type of this datafield
- Returns
- string type of entry
◆ getValue()
Returns the value of the datafield
- Returns
- mixed containing the value
◆ isEditable()
| isEditable |
( |
|
$perms = null | ) |
|
Returns whether the datafield is editable for the current user
- Parameters
-
| mixed | $perms | Perms to test against (optional, defaults to logged in user's perms) |
- Returns
- boolean indicating whether the datafield is editable
◆ isEmpty()
◆ isI18N()
Returns whether the datafield is an i18n field.
- Returns
- boolean indicating whether the datafield is a 18n field
◆ isRequired()
Returns whether this datafield is required
- Returns
- bool indicating whether the datafield is required or not
◆ isValid()
◆ isVisible()
| isVisible |
( |
|
$perm = null, |
|
|
|
$test_ownership = true |
|
) |
| |
Returns whether the datafield is visible for the current user
- Parameters
-
| String | $perm | Permissions to test against (optional, default to the current user's permissions) |
| bool | $test_ownership | Defines whether the ownership of the field should be taken into account; a field may be invisible for a user according to the permissions but since the datafield belongs to the user, it is visible. |
- Returns
- boolean indicating whether the datafield is visible
◆ numberOfHTMLFields()
◆ prettyPrintViewPerms()
Generates a full status description depending on the the perms
- Returns
- string
◆ removeAll()
| static removeAll |
( |
|
$range_id | ) |
|
|
static |
Removes all datafields from a given range_id (and secondary range id if passed as array)
- Parameters
-
| mixed | $range_id | Range id (or array with range id and secondary range id) |
- Returns
- int representing the number of deleted entries
◆ setContentLanguage()
| setContentLanguage |
( |
|
$language | ) |
|
Sets the prefered content language if this is an i18n datafield.
- Parameters
-
| string | $language | The prefered display language |
Reimplemented in DataFieldI18NEntry.
◆ setRangeID()
Sets the range id
- Parameters
-
◆ setSecondRangeID()
| setSecondRangeID |
( |
|
$sec_range_id | ) |
|
Sets the secondary range id
- Parameters
-
| String | $sec_range_id | Secondary range id |
◆ setValue()
Sets the value
- Parameters
-
◆ setValueFromSubmit()
| setValueFromSubmit |
( |
|
$submitted_value | ) |
|
◆ store()
Stores this datafield entry
- Returns
- int representing the number of changed entries
Reimplemented in DataFieldI18NEntry.
◆ $language
◆ $model
◆ $rangeID
◆ $supported_types
Initial value:= array(
'bool',
'textline',
'textlinei18n',
'textarea',
'textareai18n',
'textmarkup',
'textmarkupi18n',
'selectbox',
'selectboxmultiple',
'date',
'time',
'email',
'phone',
'radio',
'combo',
'link',
)
◆ $value
The documentation for this class was generated from the following file: