search for: selection_type

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

Did you mean: section_type
2008 Nov 12
5
dynamic condition for has_one and eager loading issue
Hi, I ve defined the following relation in one of my models with a dynamic where condition: has_one :selection, :foreign_key => ''object_id'', :conditions => ''selection_type = 1 and account_id = # {self.send(:account_id)}'' That works perfect, however when I try to eager load that relation I am getting the following error when doing a count. Seems that self is not really my model class anymore.... Does anybody know how I can get that up and running? Thanks a...