It is good practice to shift logic from the controller into the model. But in any complex system, this invariably leads to a very large file even if a majority of the methods are one liners as per the Rails Way.
I’ve resorted to splitting up models into other modules and including them in the original model, for example, model_flags, model_validation, etc. Anyone has a better way?
I realize this is a fairly old question and it’s been marked as answered, but it still has good Google juice, so I figured it was worth adding to…
Rails 3 introduced ActiveSupport::Concern, which can be used to modularize behavior that’s shared across models. Or, for that matter, to slim down models that have become too fat.
DHH himself provides a nice, succinct example gist here:
https://gist.github.com/1014971