I have this situation:
has_many :policy_indicator_allocations, :order => “position”
has_many :policy_indicators, :through => :policy_indicator_allocations
has_many :regions, :through => :policy_indicator_allocations
So, policy_indicator_allocations are joins between a region and a policy
indicator, for a particular year.
What i’m wondering is this: when i come to associate a policy indicator
with a region, i want to do it for a particular year. What’s the
best/most conventional way to do this? (assume i have the relevant
models in instance vars)
A not very clever way is this:
:region_id => @region.id,
:policy_indicator_id => @policy_indicator.id,
:year_id => @year.id )
Is there a neater way?