search for: current_for_user

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

2006 Jan 30
1
Multiple associations between tables - do they ever work?
...rticles, :order => "name", :dependent => :delete_all belongs_to :current_article, :class_name => "Article", :foreign_key => "current_article_id" end class Article < ActiveRecord::Base class Search < ActiveRecord::Base belongs_to :user has_one :current_for_user, :class_name =>"User", :foreign_key => "current_article_id" end I simply cannot make the "current_article" association work reliably. Ideally, I want to be able to set the current article manually (when the user selects an existing article to edit or view), a...