[TYPO3-mvc] Use repository in tca eval function

Stefan Kruse besucher80 at gmx.de
Fri Jul 5 13:35:43 CEST 2013


Hi, 

 

i need to use my own tca eval function. This works fine in so far but I need
to check if a username is already in use. Therefore I need to make a query.
I want to use my Extbase repository. I make an instance to my repo with:

 

$repo =
t3lib_div::makeInstance('SK\Tl24\Domain\Repository\CompanyRepository');

$company = $repo->findOneByUsername($value);

If(is_null($object)) {

.

}

Else {

.

}

 

But this don't work. Is this the right way or do I have to go the old way
with $GLOBALS [ 'TYPO3_DB' ]-> SELECTquery()..?

 

Cheers Stefan



More information about the TYPO3-project-typo3v4mvc mailing list