Forum: Ruby on Rails REST nested resources and resource design

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
cjharrelson (Guest)
on 2007-06-12 07:27
(Received via mailing list)
I have a situation where an account belongs_to account_type and
account_type has_many accounts.  Obviously, I also have an
AccountTypeController and an AccountController.

I am trying to get a list of all accounts that are of account type
'user' without breaking the REST conventions.  What is the best way to
achieve this?

I could accept an account_type parameter in the index action of the
AccountController and limit the list by this if it is present.

It also seems like I could go through the the AccountTypeContoller to
achieve this, but I am at a loss for how.

Thank you in advance for your help!
This topic is locked and can not be replied to.