[TYPO3-mvc] query->setOrderings: order by value list

Stephan Helten stephan.helten at engage.de
Tue Jul 5 12:01:52 CEST 2011


Hi,

they're ordered by the UID ascending, but not by the order of the UIDs in
the comma separated list.

regards

Stephan 

-----Ursprüngliche Nachricht-----
Von: typo3-project-typo3v4mvc-bounces at lists.typo3.org
[mailto:typo3-project-typo3v4mvc-bounces at lists.typo3.org] Im Auftrag von
Franz Koch
Gesendet: Dienstag, 5. Juli 2011 11:04
An: typo3-project-typo3v4mvc at lists.typo3.org
Betreff: Re: [TYPO3-mvc] query->setOrderings: order by value list

Hey,

> The customer is able to define a custom order of the entities in the
> backend.
>
> In my person repository I have a function findByUids expecting a comma
> separated list of uids (from the flexform value).
>
> Wouldn't it be nice to have the ability to call query->setOrderings with
the
> provided list to define the ordering exactly as given in the backend?

shouldn't the objects automatically be selected in the order you defined 
in the uid list? That's at least the case for me IIRC. Of course you 
must take care to not apply default orderings you probably set for your 
repository.

-- 
kind regards,
Franz Koch
_______________________________________________
TYPO3-project-typo3v4mvc mailing list
TYPO3-project-typo3v4mvc at lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-project-typo3v4mvc



More information about the TYPO3-project-typo3v4mvc mailing list