Hi there
I am writing an api layer to serve as a passthrough for Solr searches. I won't go into the reasoning for this now, but the result is a class I'm calling Hit that is not an ActiveRecord. As the name suggests, it's simply modeled on a "search result" from Solr. So, this thing doesn't have any ActiveModel trappings whatsoever.
That said, I have set up the "searchable" block in the normal way (though, I'm bypassing Sunspot's use of Solr's dynamic fields). When I conduct a search, and specify an 'fq' I get the error mention in the subject of this thread:
Hit.search do
keywords "foo"
with :myfield, "my value"
end
This is resulting in the following error: NoMethodError: undefined method `gsub' for :myfield:Symbol.
I see in the Scope class in the sunspot-rails dsl library where it's happening, but rather than follow the trail, I thought I'd ask and see if I get a quicker response than my searching will yield. Any ideas?
-David