search for: find_by_is_primary_ag

Displaying 1 result from an estimated 1 matches for "find_by_is_primary_ag".

2006 May 07
4
Getting column value from lookup table in HABTM relationship
I have a HABTM relationship between my agents and listings tables. Each listing can have many agents and each agent can have many listings. In the agents_listings table I have a column called ''is_primary_agent'' which denotes if the agent is responsible for the listing - only one agent can be primary. At the moment I use this in my listing_controller''s view