railsforcharity/spokenvote — pull request #57 by kimardenmiller (2013-01-23 01:52:50+00:00)
Title: Move hub link direct to proposals

This version has many changed code references to accomodate the new schema and seems to completely work, except for searching by Hub.

Also, I was a bit foggy on exactly how to relate Votes and Hubs. I ended up with:

Votes: (the last two being commented out)
````
belongs_to :hub, inverse_of: :votes # Replaces # belongs_to :hu
# belongs_to :hub, through: :proposal # Kim's experiments creating an association to hubs
# has_one :hub through: :proposal # Kim's experiments creating an association to hubs
````
and Hubs:
````
has_many :votes, through: :proposals
````