How do I do a has_many through association on a has_many through association in rails?
- by Angela
Warning: I may have the wrong 'problem statement' but here it goes:
A Campaign has many Contacts.
A Campaign has many Emails.
Therefore, a Contact has many Emails through a Campaign.
And an Email can have many Contacts through a Campaign.
Each Contact-Email pair has its own unique Status (status1, status2, etc).
Each Status (for a Contact-Email pair) will have its own User.
I do not know how to model Status, or User. Currently the immediate challenge is Status.
(see diagram below)