[TYPO3-mvc] Map table as model

Dawid Pacholczyk dpacholczyk at gmail.com
Wed Mar 2 11:31:49 CET 2011


W dniu 2011-03-02 10:39, Dawid Pacholczyk pisze:
> Hello List,
> I would like to map an existing table as my own model in my ext.
>
> I would like to have in my ext an model "BeUser"
>
> So I did this ts in my setup.txt
>
> plugin.tx_ext {
> persistence {
> storagePid = 5
> classes {
> Tx_Ext_Domain_Model_BeUser {
> mapping {
> tableName = be_users
> recordType = Tx_Ext_Domain_Model_BeUser
> }
> }
> }
> }
> }
>
> I`ve created a model and repository but I get nothing when i user
> $berepo->findAll()
>
> what am I doing wrong ?
>
> Best regards,
> Dawid Pacholczyk

I`ve solved one problem and discovered another one.

First of all be_users MUST BE in pid 0 so my storagePid = 5 is creating 
the problem. When I delete this settings then I get access to be_users 
BUT I lose access to othere original records cause there is no PID set :/

How to solve this ?


More information about the TYPO3-project-typo3v4mvc mailing list