Implement paginate() and paginateCount() in the model with your custom querys.

2007/11/30, Bram <[EMAIL PROTECTED]>:
>
> Hi all,
>
> Here comes part 2 of my newby questions serie.
>
> I've a model called Company that has multiple ratings. The rating
> contains a number from 1 to 5. The rating of the company is calculated
> using an avg() on the rating field of all ratings. In the view of 1
> company, I'm doing this with a custom mysql query. In the paginated
> listing of companies, I would like to display the rating also and be
> able to sort on in. So, what would be the best way to do this using
> Cakephp 1.2? I saw a few pointers to changing findAll and such, but I
> would like to know what's the best way to do this at the moment.
>
> Bram
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
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