how I can get the has_many associations of a model?
For example if I have this class:
class A < ActiveRecord::Base
has_many B
has_many C
end
I would a method like this:
A.get_has_many
that return
[B,C]
Is it possible? Thanks!
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…