I have models Trip
, Investment
, and Person
. A single trip hasMany investments, and every investment belongsTo one Person. When I say $this->Trip->find('all');
I get:
Array (
[0] => Array (
[Trip] => Array (
[id] => 1
[date] => 2012-10-25 13:00:00
)
[Investments] => Array (
[0] => Array (
[id] => 1
[person_id] => 1
[investment_type_id] => 2
[trip_id] => 1
[investment] => 55
)
[1] => Array (
[id] => 2
[person_id] => 2
[investment_type_id] => 1
[trip_id] => 1
[investment] => 40
)
)
)
)
I would like each investment to include the information about the person represented by person_id
(So their id
, their name
, etc). I've tried all levels of recursion on the find('all')
lookup with no luck.