Relation 1:n (Selectorbox) or Relation n:n (Double Selectorbox)
| Property | Data type | Default | Plus | Mvc |
|---|---|---|---|---|
| additionalJoinTableSelect | String | Yes | No | |
| additionalTableSelect | String | Yes | No | |
| aliasSelect | Field name | Yes | No | |
| applyFuncToRecords | Boolean | 0 | Yes | No |
| groupBySelect | String | Yes | No | |
| labelSelect | Field name | Yes | Yes | |
| orderSelect | String | Yes | Yes | |
| overrideEnableFields | Boolean | 0 | Yes | No |
| overrideStartingPoint | Boolean | 0 | Yes | No |
| separator | String | Yes | No | |
| singleWindow | Boolean | 0 | Yes | Yes |
| specialFields | String | Yes | No | |
| whereSelect | String | Yes | Yes |
additionalJoinTableSelect
- Property
- additionalJoinTableSelect
- Data type
- String
- Description
- It adds the string in the FROM part of the select query. It can be used when tables need to be joined using JOIN statements.
additionalTableSelect
- Property
- additionalTableSelect
- Data type
- String
- Description
- The string is a comma-separated table names. It adds the table names in the select query. It can be used when tables need to be joined without JOIN statements.
aliasSelect
- Property
- aliasSelect
- Data type
- Field name
- Description
- Defines an alias used in the SELECT query. Markers
###fieldname###can be used,fieldnamemust be in the relation table.
applyFuncToRecords
- Property
- applyFuncToRecords
- Data type
- Boolean
- Description
- If true the function defined by the
funcattribute is applied to each record of a double selector in the single view. - Default
- 0
content
- Property
content
- Data type
- SQL SELECT statement
- Description
-
SQL SELECT statement must have an alias
uidand an aliaslabelwhich will be used as the value to display. Special markers can be used in the statement :###uid###will be replaced by the current record uid.###uidSelected###will be replaced by the selected item.###user###will be replaced by the user id.###cruser###will be replaced by the user id.
The following example returns a selectorbox with the usernames that are linked with the user by a MM relation:
content = SELECT fe_users.uid as uid, fe_users.name as label FROM tx_mytable_rel_myfield_mm,fe_users WHERE tx_mytable_rel_myfields_mm.uid_local=###user### AND tx_mytable_rel_myfields_mm.uid_foreign=fe_users.uid ORDER by label;Copied!
groupBySelect
- Property
groupBySelect
- Data type
- String
- Description
- Defines the GROUP BY clause for the selector.
labelSelect
- Property
labelSelect
- Data type
- Field name
- Description
-
Defines the label from the field name for the selector.
..important:
This property is mandatory for repositories not designed for SAV Library Mvc, e.g. Extbase FrontendUserRepository or FrontendUserGroupRepository.
orderSelect
- Property
- orderSelect
- Data type
String
- Description
- Define the order clause for the selector. In general: fieldname [desc].
overrideEnableFields
- Property
- overrideEnableFields
- Data type
- Boolean
- Description
-
If set, the method enableFields of the class tslib_cObj which filters out records with start/end times or hidden/fe_groups fields is not applied to the query associated with the selectorbox.
It may be used in specific cases when you needed to retreive all the records.
- Default
- 0
overrideStartingPoint
- Property
- overrideStartingPoint
- Data type
Boolean
- Description
- By default, when starting points are provided, information associated with the selector is searched in these page. This property overrides the default behavior.
- Default
- 0
separator
- Property
separator
- Data type
String
- Description
- It should be used when the max number of relations is greater than 1 (not true MM-relation) to replace the default <br /> separator between items in showAll or showSingle views.
singleWindow
- Property
- singleWindow
- Data type
Boolean
- Description
- In case of a MM relation, a double window is used to select items. When this option is used, a single selectorbox in multiple mode is used.
- Default
- 0
specialFields
- Property
specialFields
- Data type
- comma-separated list of fields
- Description
- The value of the fields will be propagated in the
###special[fieldname]### markerwhen available.
whereSelect
- Property
whereSelect
- Data type
- String
- Description
-
Defines the WHERE clause for the selector. It can be:
- a conventional MySQL clause. The marker
###user###will be replaced by the user uid.The marker###uid###or###uidMainTable###will be replaced by the main current record. The marker###CURRENT_PID###will be replaced by the current page uid. - ###group_list = list_of_comma_separed_fe_groups###. To be used
with a selector on
fe_users. It checks if the user belongs to the group list. - ###group_list != list_of_comma_separed_fe_groups###. To be used
with a selector on
fe_users. It checks if the user does not belong to the group list.
- a conventional MySQL clause. The marker