http://cakephp.lighthouseapp.com/projects/42648/tickets/95-afterfind-and-beforefind-callbacks-not-working-on-associated-models-was-translate-behavior-should-translate-associated-model-data
On Feb 26, 1:16 pm, Rafel <rafe...@gmail.com> wrote:
> Hello, I have a model categories with the field name translated at
> the table i18n, the problem comes when I want to show the articles
> with their associated categories, that doesn't return the names of the
> categories of each language translation.
>
> If i write 'recursive' =2 in the find query, I get it, but a high
> recursive make so many unnecessarily queries, so I use the 'contain'
> Behavior to get the categories with their names translated but
> there is no way to get.
>
> In the category $actAs, I have this:
>
> var $actAs = array ( 'Translate' => array ( 'c_name' =>
> 'c_nameTranslation'));
>
> In the contain i have this 'Category.c_nameTranslation', but the
> query fails because doesn't recognize the field, someone can help me?.
> Cakephp allows the return of the translations of other associated
> models?
>
> Thanks!
Check out the new CakePHP Questions site http://cakeqs.org and help others with their CakePHP related questions.
You received this message because you are subscribed to the Google Groups "CakePHP" group.
To post to this group, send email to cake-php@googlegroups.com
To unsubscribe from this group, send email to
cake-php+unsubscribe@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en
No comments:
Post a Comment