So, this was great but I'm wondering if I can go a bit further with
this.

All these tables have queries that are very similar, so similar that I
could use exactly the same code in most of them, like here's an
example:
[code]
function getByKit($type, $id)
{
        $rows = $this->find($type, array(
            'conditions' => array('kit_id' => $id),
            'order' => array($displayField),
            )
);
       return $rows;
}
[/code]

So where would it make sense to put this without having to duplicate
it in every model?  Is there something like app_controller.php for
models?

Thanks!
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"CakePHP" group.
To post to this group, send email to [email protected]
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