The issue is that you are overwriting the $hasMany array with each new
declaration so only the last hasMany relationship will be created
(Upload). As Milmar says you need to group multiple relation types
into a single array as follows:
var $hasMany = array('Article', 'Event', 'Post', 'Price',
'Upload');
However over time you will almost certainly need to expand on these
relationship declarations and include extra parameters (as Milmar
shows above) to eliminate the fetching of extra unwanted data which
may slow your app down. Takes a while to get your head around but it
eventually all falls into place and makes perfect sense.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---