sub accounts

I am using restful authentication and was wondering if anyone has had any experience with sub accounts. Basically, I want a user to have the ability to add another user(s) to his/her account. So if user A creates an account I would like them to have the ability to add new users to their account - B, C, etc. B and C would "belong" to A and if A's account is deleted so is B and C. Makes sense? Any information on how to achieve this would be greatly appreciated.

mlittle wrote:

I am using restful authentication and was wondering if anyone has had any experience with sub accounts. Basically, I want a user to have the ability to add another user(s) to his/her account. So if user A creates an account I would like them to have the ability to add new users to their account - B, C, etc. B and C would "belong" to A and if A's account is deleted so is B and C. Makes sense? Any information on how to achieve this would be greatly appreciated.

This can be done by using the relationships among the tables. I suggest the following database model:

Users ( Table )

Seems too easy :). How would I handle the confirmation email and related issues? Thanks a bunch for the response. I do appreciate it!!

mlittle wrote:

I'm going to look at the code more but I was talking about creating the user just like I would with restful_authentication. I see what you are saying but I am still not clear how the new user in sub_user would be able to login, logout, and basically do the same as the users in Users.

Anyone else able to provide me with some insight on implementing this?