RailsCasts Pro episodes are now free!

Learn more or hide this

OCADA's Profile

GitHub User: OCADA

Comments by


Great screencast!
I noticed it's really easy to implement this with the virtual attribute tagging tutorial (with various taggings with tags). Like so:

text :taggings do
        taggings.map{ |tagging| tagging.tag.name }

I've just implemented the tagging thing right into my system and built around it - and now I'm realising that I don't have a clue how to search for the tags. Is there any easy way to search (using something similar to the simple searching railscast) both my tutorial names and their tags (in which taggings are done via this tutorial).
My current super simple search code is below:

find(:all, :conditions => ['name LIKE ?', "%#{search}%"])

Any help?