Where would people put the actions for the following scenario? I have three models: users, messages and permissions. Certain users can see certain messages that are left, thanks to the permissions table (which simply links user_id to message_id). I currently have three controllers: Login: login, logout, add_user (etc) Messages: for the users Admin: for the administrator, add_message, edit_message (etc) Maybe the user functions should be moved into the AdminController? Maybe I'm way off here? It seems that controllers should lump together groups of functionality, but they could end up huge. In the future I might add groups (which will require add_group, adding users to groups for the administrator). Is this really best in the Admin controller? I can see it getting very unwieldy. The pragmatic book keeps things in two controllers, one for the "user" tasks and one for the "admin" tasks. I've tried keeping it like that for my application, but it seems like I could end up with one controller per model almost, which seems wrong for many reasons (e.g. views are actually common to them all). Any advice on how to begin thinking about this would be greatly appreciated.
on 2006-03-10 22:24