> $this->Person->contain('Hobby', 'Job'); I've never seen anyone set containable options like above, I thought they had to be within the find options array
$this->Person->find('first', array(contain=>array('Hobby', 'Job'))); I don't see how your conditions array can be set the same for every model within your schema as I doubt every model is directly associated to People for the conditions People.schedule_id to work. All you're really talking about is a single line of common code $this->Model->find('all/first/list', array( 'conditions'=>array( 'Model.condition1'=>'value' 'Person.schedule_id'=>$this->Session->read('Schedule.id') // your one common line ) )); If you do set a common conditions array in app_controller then you would have to include a line in every controller action to merge it with the other conditions you are applying for each actions finds ... I can't see how this is going to save you any code, it sounds like more work to me personally. And what about the finds where a user is not logged in/has not created a session, they can't have a schedule_id set? HTH Paul. 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+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/cake-php?hl=en