posts = Post.all tags = posts.tags # That is really bad because Rails is doing too many queries in database, we can make it better: posts = Post.find(:all, include: :tags) # Not too many queries in database, more performance
sexta-feira, 28 de fevereiro de 2014
Rails tips
Assinar:
Postagens (Atom)