Replaces find(:all) calls.
Replaces acts_as_tree #roots class method with a scope.
Load RMagick before the gantt helper (#12097).
Removed unused instance variable.
Fixed dependency loading for when running in dev mode (#12097).