Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/andersundsehr/relation-processor
Adds DataProcessor to resolve all types of TCA Relations
https://github.com/andersundsehr/relation-processor
data-processor data-processors dataprocessor dataprocessors typo3 typo3-extension
Last synced: about 2 months ago
JSON representation
Adds DataProcessor to resolve all types of TCA Relations
- Host: GitHub
- URL: https://github.com/andersundsehr/relation-processor
- Owner: andersundsehr
- Created: 2023-12-13T11:07:47.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-07-01T11:05:35.000Z (6 months ago)
- Last Synced: 2024-10-02T08:37:19.831Z (3 months ago)
- Topics: data-processor, data-processors, dataprocessor, dataprocessors, typo3, typo3-extension
- Language: PHP
- Homepage:
- Size: 157 KB
- Stars: 2
- Watchers: 2
- Forks: 2
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# EXT:relation_processor
## install
``composer req andersundsehr/relation-processor``
## what does it do
It adds a RelationProcessor so you don't have to manually define a DatabaseQueryProcessor for each relation you want to use.
It uses the TCA configuration to determine the correct query to use.
It uses the `PageRepository->versionOL()` and `PageRepository->getLanguageOverlay()` functions so it hase correct versioning and language overlay support.### Example
````ts
10 = AUS\RelationProcessor\DataProcessing\RelationProcessor
10 {
# this field is of the current table and will be used to determine the relation
# eg. if you have EXT:news and this processor is used on a tt_content you can get all related news like this:
field = tx_news_related_news
}
````### Advanced Example
````ts
page = PAGE
page.10 = FLUIDTEMPLATE
page.10 {
dataProcessing {
10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor
10 {
references.fieldName = header_image
as = headerImage
}20 = AUS\RelationProcessor\DataProcessing\RelationProcessor
20 {
field = tx_customerproduct_companiesdataProcessing {
10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor
10 {
references.fieldName = header_image
as = headerImage
}20 = AUS\RelationProcessor\DataProcessing\RelationProcessor
20 {
field = tx_customercompany_product_familydataProcessing {
10 = TYPO3\CMS\Frontend\DataProcessing\FilesProcessor
10 {
references.fieldName = header_image
as = headerImage
}
}
}
}
}
}
}
````# with ♥️ from anders und sehr GmbH
> If something did not work 😮
> or you appreciate this Extension 🥰 let us know.> We are hiring https://www.andersundsehr.com/karriere/