Hey that works too, and is more elegant. Thanks for the suggestion!
On Dec 5, 4:52 pm, euromark wrote:
> ah thats what you mean
> did you try setting $displayField of that model to "name"?
> that should also work
>
> On 5 Dez., 19:04, aries wrote:
>
>
>
>
>
>
>
> > Solution:
>
> > In the Region
ah thats what you mean
did you try setting $displayField of that model to "name"?
that should also work
On 5 Dez., 19:04, aries wrote:
> Solution:
>
> In the Regions controller, I have to specify the find fields, viz:
>
> $reporters = $this->Region->Reporter->find('list', array('fields' =>
> arr
Solution:
In the Regions controller, I have to specify the find fields, viz:
$reporters = $this->Region->Reporter->find('list', array('fields' =>
array('id', 'name')));
Thanks,
-Brian
On Dec 5, 11:45 am, aries wrote:
> Hi there,
>
> Thanks for your response. I should have clarified my situatio
Hi there,
Thanks for your response. I should have clarified my situation. I have
a form for a related Region model (HABTM relationship) that calls
$this->Form->input('Reporter'); to show a multi select list of
Reporter records. I figured that adding a virtual name field called
"name" would auto-po
you might be doing sth wrong
how are you processing the result?
because Reporter__name is correct so far.
cake will then automatically merge the content of this key back to the
Model result array with the key "name".
and then it should be available with
$result['Reporter']['name']
since "name" an