[TYPO3-mvc] Integration of TYO3 Corefeatures in Extbase

Henjo Hoeksma | Stylence me at henjohoeksma.nl
Wed Feb 20 15:50:53 CET 2013


Hi Philip,

did you add 'your own' category object?

I do use it that way:

class Category extends \TYPO3\CMS\Extbase\Domain\Model\Category {

}

but it should be working directly too...

Kind regards,

Henjo

Problems are small because we learned how to deal with them.
Problems are big because we need to learn how to deal with them.


On Wed, Feb 20, 2013 at 2:49 PM, Philipp <philippwrann at gmx.at> wrote:

> 1) I need to get records that have categories, like a simple join. But i
> want to know if i can do it in the repository with matchings or if i have
> to do direct sql instead.
>
> I would prefere something like
> $query->matching($query->has(**categories,$categories))
>
> I have to admit, i have not realized much in extbase so far.
>
> The categorization is done with\ TYPO3\CMS\Core\Utility\**
> ExtensionManagementUtility::**makeCategorizable
>
> jus like its ment to be i think.
>
> My mapping in the Model should be like this i think:
> /**
> * The categories of the regional object
> * @var \TYPO3\CMS\Extbase\**Persistence\ObjectStorage<\**
> TYPO3\CMS\Extbase\Domain\**Model\Category>
> */
> protected $categories;
>
> But when i set this mapping extbase throws me an error because of the type
>
> #########
> My solution with the FAL problem was:
> placing a underscored property in the model (to make it non-persistent)
> named _images
> I tried @transient too, but it didnt work
> Type = array
>
> Then ive written the set/get/add methods
>
> In my controller ive written a method called addImages
> The method checks if the object implements my falfixinterface (where i
> define the add/set/get methods needed) and adds all the images to the
> _images property by making a instance of the filerepository and calling
> findByRelation.
>
> Pretty simple so far, but just a workaround.
>
> Then i created to ViewHelpers, which extend the original image ViewHelpers
> and get the options from the FileReference...
> ######
>
> ______________________________**_________________
> TYPO3-project-typo3v4mvc mailing list
> TYPO3-project-typo3v4mvc@**lists.typo3.org<TYPO3-project-typo3v4mvc at lists.typo3.org>
> http://lists.typo3.org/cgi-**bin/mailman/listinfo/typo3-**
> project-typo3v4mvc<http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc>
>


More information about the TYPO3-project-typo3v4mvc mailing list