One way of doing this is to add a "defaultPhotoID" field to the photo
gallery record...
(and of course removing the "default" flag from the photos)

a nice side effect is that it allows you to share photos between
galleries... maybe not something that one would do, but replace the
gallery with group and photo with articles... or just about any other
example :)

I also like to ask questions like: default photo is an attribute of
which entity? photo or gallery?

Goran

Jaime wrote:
> is set in the Photo model. Of course one and only one photo within
> that album should have the "default" bit set, because it's non-sense
> to flag more than one for the same album.

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" group.
To post to this group, send email to cake-php@googlegroups.com
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