‪TYPO3CMS  11.5
TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem Class Reference
Inheritance diagram for TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem:
TYPO3\CMS\Backend\Form\FormDataProviderInterface

Public Member Functions

array addData (array $result)
 

Protected Member Functions

array addFieldsBySubtypeAddList (array $result, $subtypeFieldName, $subtypeValue, $recordTypeValue)
 
array removeFieldsBySubtypeExcludeList (array $result, $subtypeValue, $recordTypeValue)
 
array removeFieldsByBitmaskExcludeBits (array $result, $bitmaskValue, $recordTypeValue)
 
array removeFields (array $result, array $removeListArray, $recordTypeValue)
 
array removeFieldsFromPalettes (array $result, $removeListArray)
 

Protected Attributes

array $processedTca
 

Detailed Description

Create final showitem configuration in processedTca for types and palette fields Handles all the nasty details like subtypes_addlist and friends.

Definition at line 27 of file TcaTypesShowitem.php.

Member Function Documentation

◆ addData()

◆ addFieldsBySubtypeAddList()

array TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem::addFieldsBySubtypeAddList ( array  $result,
  $subtypeFieldName,
  $subtypeValue,
  $recordTypeValue 
)
protected

Insert additional fields in showitem based on subtypes_addlist

databaseRow['theSubtypeValueField'] = 'theSubtypeValue' showitem = 'foo,theSubtypeValueField,bar' subtype_value_field = 'theSubtypeValueField' subtypes_addlist['theSubtypeValue'] = 'additionalField'

-> showitem = 'foo,theSubtypeValueField,additionalField,bar'

Parameters
array$result‪Result array
string$subtypeFieldName‪Field name holding subtype value
string$subtypeValue‪subtype value
string$recordTypeValue‪Given record type value
Returns
‪array Modified result array

Definition at line 96 of file TcaTypesShowitem.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\addData().

◆ removeFields()

array TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem::removeFields ( array  $result,
array  $removeListArray,
  $recordTypeValue 
)
protected

Remove fields from show item field list

Parameters
array$result‪Given show item list
array$removeListArray‪Fields to remove
string$recordTypeValue‪Given record type value
Returns
‪array Modified result array

Definition at line 211 of file TcaTypesShowitem.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFieldsByBitmaskExcludeBits(), and TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFieldsBySubtypeExcludeList().

◆ removeFieldsByBitmaskExcludeBits()

array TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem::removeFieldsByBitmaskExcludeBits ( array  $result,
  $bitmaskValue,
  $recordTypeValue 
)
protected

Remove fields from showitem based on subtypes_excludelist

databaseRow['theSubtypeValueField'] = 5 // 1 0 1 showitem = 'foo,toRemoveBy4,bar' bitmask_value_field = 'theSubtypeValueField' bitmask_excludelist_bits[+2] = 'toRemoveBy4'

-> showitem = 'foo,bar'

Parameters
array$result‪Result array
int$bitmaskValue‪subtype value
string$recordTypeValue‪Given record type value
Returns
‪array Modified result array

Definition at line 184 of file TcaTypesShowitem.php.

References TYPO3\CMS\Core\Utility\MathUtility\forceIntegerInRange(), TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFields(), TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFieldsFromPalettes(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\addData().

◆ removeFieldsBySubtypeExcludeList()

array TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem::removeFieldsBySubtypeExcludeList ( array  $result,
  $subtypeValue,
  $recordTypeValue 
)
protected

Remove fields from showitem based on subtypes_excludelist

databaseRow['theSubtypeValueField'] = 'theSubtypeValue' showitem = 'foo,toRemove,bar' subtype_value_field = 'theSubtypeValueField' subtypes_excludelist['theSubtypeValue'] = 'toRemove'

-> showitem = 'foo,bar'

Parameters
array$result‪Result array
string$subtypeValue‪subtype value
string$recordTypeValue‪Given record type value
Returns
‪array Modified result array

Definition at line 156 of file TcaTypesShowitem.php.

References TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFields(), TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFieldsFromPalettes(), and TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\addData().

◆ removeFieldsFromPalettes()

array TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem::removeFieldsFromPalettes ( array  $result,
  $removeListArray 
)
protected

Remove a list of element from all palettes

Parameters
array$result‪Result array
array$removeListArray‪Array of elements to remove
Returns
‪array Modified result array
Todo:
‪: unit tests!

Definition at line 238 of file TcaTypesShowitem.php.

References TYPO3\CMS\Core\Utility\GeneralUtility\trimExplode().

Referenced by TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFieldsByBitmaskExcludeBits(), and TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem\removeFieldsBySubtypeExcludeList().

Member Data Documentation

◆ $processedTca

array TYPO3\CMS\Backend\Form\FormDataProvider\TcaTypesShowitem::$processedTca
protected

Processed TCA array

Definition at line 33 of file TcaTypesShowitem.php.