Files
VITEC-website/packages/vitec/Configuration/TypoScript/Headless/vitec_containers.typoscript
o-rasche 409afc2433 VITEC headless: ContentElementResolver, Product fields (videofile, showdatapath)
- New Classes/Service/ContentElementResolver.php: parses TYPO3 typolink
  (t3://record?identifier=tt_content&uid=N, t3://page?uid=P#N, plain numeric)
  to a normalised tt_content envelope ({id,type,colPos,sorting,appearance,
  data}), recursively resolving any nested VITEC list-plugin children.
- ProductListJsonRenderer / ProductShowJsonRenderer: contentelement and
  contentelementcta now emit the resolved object instead of the raw
  typolink string (breaking change at those two keys).
- Product model: new field videofile (FAL, single video upload in tab
  Images and Videos, mp4/webm/ogv/mov/m4v); new bool field showdatapath
  (toggle at end of General tab, controls the "Datapath is now Vitec"
  graphic in the frontend). ext_tables.sql, TCA, model property +
  getter/setter, and both renderers updated accordingly.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-06-05 10:34:49 +02:00

101 lines
3.5 KiB
Plaintext

# =============================================================================
# VITEC container content elements — self-contained JSON rendering
# Children collected via Evomedien\Vitec\DataProcessing\ContainerChildrenProcessor
# (exception-safe; returns [] on any error, never crashes the outer CE).
# =============================================================================
tt_content.vitec_cols_50_50 = JSON
tt_content.vitec_cols_50_50 {
fields {
id = INT
id.field = uid
type = TEXT
type.field = CType
colPos = INT
colPos.field = colPos
categories = COA
categories {
10 = CONTENT
10 {
table = sys_category
select {
pidInList = root
selectFields = sys_category.title
join = sys_category_record_mm on sys_category_record_mm.uid_local = sys_category.uid
where {
field = uid
wrap = AND sys_category_record_mm.tablenames = 'tt_content' AND sys_category_record_mm.uid_foreign=|
}
}
renderObj = TEXT
renderObj {
field = title
wrap = |###BREAK###
}
}
stdWrap.split {
token = ###BREAK###
cObjNum = 1 |*|2|*| 3
1 {
current = 1
stdWrap.wrap = |
}
2 {
current = 1
stdWrap.wrap = ,|
}
3 {
current = 1
stdWrap.wrap = |
}
}
}
appearance = JSON
appearance {
fields {
layout = TEXT
layout.field = layout
frameClass = TEXT
frameClass.field = frame_class
spaceBefore = TEXT
spaceBefore.field = space_before_class
spaceAfter = TEXT
spaceAfter.field = space_after_class
}
}
header = TEXT
header.field = header
subheader = TEXT
subheader.field = subheader
tx_vitec_bg_variant = TEXT
tx_vitec_bg_variant.field = tx_vitec_bg_variant
items = JSON
items {
dataProcessing {
10 = Evomedien\Vitec\DataProcessing\ContainerChildrenProcessor
10.as = items
}
}
}
}
tt_content.vitec_cols_33_33_33 =< tt_content.vitec_cols_50_50
tt_content.vitec_cols_25_25_25_25 =< tt_content.vitec_cols_50_50
tt_content.vitec_cols_66_33 =< tt_content.vitec_cols_50_50
tt_content.vitec_cols_33_66 =< tt_content.vitec_cols_50_50
# -----------------------------------------------------------------------------
# VITEC · Container — single-column container with a custom CSS class.
# Inherits the full structure of the grid containers and adds the `cssClass`
# field, read from the element's FlexForm (settings.cssClass).
# -----------------------------------------------------------------------------
tt_content.vitec_container =< tt_content.vitec_cols_50_50
tt_content.vitec_container.fields.cssClass = TEXT
tt_content.vitec_container.fields.cssClass.data = flexform:pi_flexform:settings.cssClass
tt_content.vitec_container.fields.cssClass.stdWrap.ifEmpty.cObject = TEXT
tt_content.vitec_container.fields.cssClass.stdWrap.ifEmpty.cObject.value =