Definition at line 7 of file Widget.php.
◆ __construct()
| __construct |
( |
|
$config = null | ) |
|
◆ _get()
Default getter if no specific setter is defined, and the property is also not published (readable).
- Parameters
-
| string | $key | Name of the property. |
- Returns
- mixed Value.
Reimplemented from Thing.
Definition at line 443 of file Widget.php.
◆ actionHelp()
◆ caption()
◆ check()
Check a value.
- Parameters
-
| mixed | $value | Value in standard, internal format. |
- Returns
- string Error code (empty = OK).
Definition at line 314 of file Widget.php.
◆ checkMax()
◆ checkMin()
◆ checkRequired()
Required check.
This check will only be called when the value is empty. If the required parameter has the value self::VALID_FUNC, then the checkValidFunc() function will be used to determine whether the value is correct (allowed empty). If the required parameter is an array, the first entry is seen as an reference to another widget (e.g. 'List__*__Name' - where the asterisk will be replaced with the current index). Its value will then be used for an comparison with an operator (2nd entry) and a value (3rd entry). If this comparison returns true, the value is required.
Definition at line 294 of file Widget.php.
◆ checkValidFunc()
◆ clientConfig()
Public configuration.
- Returns
- array Public configuration for this widget in key => value pairs.
Reimplemented in Table, File, Char, Options, Phone, DateTime, Lookup, Grid, Number, Email, Group, and Time.
Definition at line 105 of file Widget.php.
◆ clientConvert()
Convert a value from client format to standard, internal format.
- Parameters
-
| mixed | $value | Value in client format. |
- Returns
- mixed Value in standard, internal format.
Reimplemented in Table, Group, and Check.
Definition at line 169 of file Widget.php.
◆ clientFormat()
Format a value from standard, internal format to client format.
- Parameters
-
| mixed | $value | Value in standard, internal format. |
- Returns
- mixed Value in client format.
Reimplemented in Table.
Definition at line 193 of file Widget.php.
◆ config()
| config |
( |
|
$key, |
|
|
|
$default = null |
|
) |
| |
|
protected |
Get single configuration value.
- Parameters
-
| string | $key | Key. |
| mixed | $default | Default value. |
- Returns
- mixed Value.
Definition at line 98 of file Widget.php.
◆ convert()
Convert a value from user format to standard, internal format.
- Parameters
-
| mixed | $value | Value in user format. |
- Returns
- mixed Value in standard, internal format.
Reimplemented in Table, Number, Grid, Group, Time, Date, and Check.
Definition at line 161 of file Widget.php.
◆ dataConvert()
Convert an internal value before it is stored in the request data.
- Parameters
-
| mixed | $value | Value in internal format. |
- Returns
- mixed Value in request data format.
Reimplemented in Group, and DateTime.
Definition at line 177 of file Widget.php.
◆ execute()
Execute an action on this widget.
Security checks are executed before. All input and output is handled through the request component. An action can only trust the values from the data array. An action must check if the widget is writeable for actions that perform 'write like' behaviour.
- Parameters
-
Definition at line 244 of file Widget.php.
◆ executeChild()
Execute an action on a child widget.
- Parameters
-
| array | $id | Child ID (everything after the parent ID). |
Reimplemented in Group, and Grid.
Definition at line 234 of file Widget.php.
◆ expect()
Note if an action is expected.
- Parameters
-
Definition at line 227 of file Widget.php.
◆ format()
Format a value from standard, internal format to user format.
- Parameters
-
| mixed | $value | Value in standard, internal format. |
- Returns
- mixed Value in user format.
Reimplemented in Table, Group, Time, Date, Check, and Color.
Definition at line 185 of file Widget.php.
◆ formatTag()
Format a tag value.
- Parameters
-
| mixed | $value | Value in standard, internal format. |
- Returns
- mixed Value in user format.
Reimplemented in Char.
Definition at line 201 of file Widget.php.
◆ getDisplay()
◆ getFred()
◆ getId()
◆ getParams()
◆ getReadable()
◆ getRight()
◆ getTags()
◆ getWidgets()
◆ getWriteable()
◆ hint()
◆ indexId()
| indexId |
( |
|
$id, |
|
|
|
$join = false |
|
) |
| |
|
protected |
Add indexes to an ID (with wildcards).
- Parameters
-
| string | $id | Base ID (with wildcards). |
| bool | $join | Set to true to return a string again (otherwise array with sub ID's). |
- Returns
- array|string
Definition at line 263 of file Widget.php.
◆ init()
◆ meta()
| meta |
( |
|
$key, |
|
|
|
$default = null |
|
) |
| |
Get a meta data value.
- Parameters
-
| string | $key | Key. |
| mixed | $default | Default value. |
- Returns
- mixed Value.
Definition at line 153 of file Widget.php.
◆ nothing()
Check if a value is empty.
- Parameters
-
- Returns
- bool True when empty.
Definition at line 274 of file Widget.php.
◆ purge()
Purge a value.
- Parameters
-
- Returns
- string Purged value.
Definition at line 217 of file Widget.php.
◆ purgeBase()
◆ setController()
◆ update()
Update the widget configuration.
- Parameters
-
| array | $config | New configuration (key-value pairs). Old values, which are not in the new configuration, are preserved. |
Definition at line 88 of file Widget.php.
◆ $_config
◆ $_controller
◆ $_display
◆ $_executing
Executing an direct action on the widget.
Definition at line 67 of file Widget.php.
◆ $_id
◆ $_meta
◆ $_params
◆ $_right
◆ $_securityChecksIgnore
| $_securityChecksIgnore = [] |
|
protected |
◆ $_tags
◆ $_widgets
Optional child widgets.
Definition at line 59 of file Widget.php.
◆ $defaultValue
◆ $help
◆ $indexes
◆ $max
◆ $min
◆ $parent
Optional parent widget.
Definition at line 54 of file Widget.php.
◆ $required
◆ $trailer
◆ $validFunc
◆ $widgetHelp
◆ CAPTION
◆ CHILD_ID_SEPARATOR
| const CHILD_ID_SEPARATOR = '__' |
◆ CLASS_NAME
| const CLASS_NAME = 'className' |
◆ DEFAULT_VALUE
| const DEFAULT_VALUE = 'defaultValue' |
◆ DISPLAY
| const DISPLAY = 'display' |
Display type (see DISPLAY_* constants).
Definition at line 14 of file Widget.php.
◆ DISPLAY_HIDDEN
| const DISPLAY_HIDDEN = 'h' |
Do not show (only hidden)
Definition at line 38 of file Widget.php.
◆ DISPLAY_MINIMAL
| const DISPLAY_MINIMAL = 'm' |
Show only value (without input element(s)).
Definition at line 39 of file Widget.php.
◆ DISPLAY_READABLE
| const DISPLAY_READABLE = 'r' |
Show input element(s), but read-only.
Definition at line 40 of file Widget.php.
◆ DISPLAY_WRITEABLE
| const DISPLAY_WRITEABLE = 'w' |
Show editable input element(s).
Definition at line 41 of file Widget.php.
◆ EVENT_ACTION_PREFIX
| const EVENT_ACTION_PREFIX = 'controller:widget:action:' |
◆ HELP
Help string (translated).
Definition at line 15 of file Widget.php.
◆ HINT
◆ MAX
◆ META
Meta data (array).
Definition at line 17 of file Widget.php.
◆ MIN
◆ PARAMS
Extra parameters for async calls (prefix the key with a '@' to point to the value of another.
Definition at line 18 of file Widget.php.
◆ REQUIRED
| const REQUIRED = 'required' |
True for required. Set to self::VALID_FUNC to let the validation function handle this. Use.
Definition at line 30 of file Widget.php.
◆ RIGHT
Optional different right with respect to the controller. If the user has the right, then (s)he.
Definition at line 20 of file Widget.php.
◆ SECURITY_CHECKS_IGNORE
| const SECURITY_CHECKS_IGNORE = 'securityChecksIgnore' |
Security checks to ignore (array with checks to ignore, true =.
Definition at line 34 of file Widget.php.
◆ TAGS
Extra tags for help, hint, and trailer.
Definition at line 23 of file Widget.php.
◆ TRAILER
| const TRAILER = 'trailer' |
Trailer string (translated).
Definition at line 22 of file Widget.php.
◆ VALID_FUNC
| const VALID_FUNC = 'validFunc' |
Specific validation function (called with value and index; returns true if OK).
Definition at line 32 of file Widget.php.
◆ WIDGET_HELP
| const WIDGET_HELP = 'widgetHelp' |
General widget help (translated).
Definition at line 24 of file Widget.php.
◆ WIDGETS
| const WIDGETS = 'widgets' |
Optional child widgets (key = name, value = widget object).
Definition at line 33 of file Widget.php.
The documentation for this class was generated from the following file:
- /var/www/fred.local/vendor/rsi/fred/src/Rsi/Fred/Controller/Widget.php