[TYPO3-english] EXTBASE config.persistence.classes

Jigal van Hemert jigal.van.hemert at typo3.org
Sun Jun 22 11:00:35 CEST 2014


Hi,

On 21-6-2014 22:31, Christian Tauscher wrote:
> I have a pi-Base Extention, this big EXT sould be moved over to EXTBASE.
>
> Since its really big with lots ob FE/BE Plugins/Modules I would like to
> first switch the FE using the perstistence Feature.
>
> But I cant get it to work:
>
> plugin.tx_movie.persistence.classes {
> 	Tx_Movie_Domain_Model_Movie.mapping {

If you're using namespaces you can use the full qualified class name here
         Tmd\Movie\Domain\Model\Movie.mapping {

> 		tableName =  tx_tmdmovie_movie <-????

Correct, you tell extbase to store the data in the table tx_tmdmovie_movie

> 		recordType =  \Tmd\Movie\Domain\Model\Movie

This is only needed if you store different objects in the same table 
(single table inheritance). Then you should have in the TCA
'type' => 'record_type' and have a field 'record_type' where the 
recordType is stored (probably easier to use the record type 'Movie').
This would be useful if you have a table 'recordings' where you want to 
store movies, series, CDs, ...; these have loads of common properties 
but also differences.
You seem to only store movies in this table, so the recordType setting 
seems not needed here.

> 		columns {
> 			artikel.mapOnProperty = artikel

These definitions are in the form
<databaseColumnName>.mapOnProperty = <nameOfPropertyInModel>

> ...
> 			trailer.mapOnProperty = youtube
> 		}
> 	}
> }

-- 
Jigal van Hemert
TYPO3 CMS Active Contributor

TYPO3 .... inspiring people to share!
Get involved: typo3.org


More information about the TYPO3-english mailing list