Created
December 9, 2014 02:05
-
-
Save wooly/b7c51dee86444f69b601 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Membership | |
has_many :profiles | |
belongs_to :current_profile | |
end | |
class MembershipProfile | |
belongs_to :team | |
belongs_to :membership | |
end | |
class Team | |
has_many :profiles, class_name: 'MembershipProfile' | |
has_many :memberships, through: :profiles | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment