STI -Defining Required Parameters

Hi everyone,

I have been struggling with this issue for some time, and I really need
some help.

I have a user system with several “accounts” each account has different
set of validation rules for a different number of attributes. I have
used STI for the accounts and setup different validation rules for each
type.

My problem is I need to get a list of the required attributes to create
each type. The only solution I see right now is to create a function
that would return a list of the required params, but I would like to
solve this with a data driven solution if I could. I can’t iterate
through the table elements because it includes the attributes for each
type.

Any ideas of how to do this? I used to have a complex solution using an
account spec, with a has_many set of params. But I want to do away with
it.

Thanks