Everything that generateList() did and more can now be done using
either find('list') or find('all') and Set::combine().  Also, I'll be
committing a patch shortly that improves the flexibility of
find('list') in terms of field handling.

On Jan 10, 4:57 pm, lordG <[EMAIL PROTECTED]> wrote:
> Yeah, I agree with what your saying on the performance... yet it is a
> slight inconvenience... this is what I have now cusomtised the
> generateList to be in my AppModel
>
>         function generateList($conditions = null, $order = null, $limit =
> null, $keyPath = null, $valuePath = null, $groupPath = null, $page =
> 1, $recursive = 0)
>         {
>                 $fields = null;
>                 if (is_array($conditions)) {
>                         if (isset($conditions['fields'])) {
>                                 $fields = $conditions['fields'];
>                         }
>                         if (isset($conditions['conditions'])) {
>                                 $conditions = $conditions['conditions'];
>                         } else {
>                                 $conditions = null;
>                         }
>                 }
>
>                 $data = $this->findAll($conditions, $fields, $order, $limit, 
> $page,
> $recursive);
>                 if (!empty($data)) {
>                         $data = Set::combine($data, $keyPath, $valuePath, 
> $groupPath);
>                 }
>                 return $data;
>         }
>
> Probably could be improved....?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/cake-php?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to