Rails 4 compatibility changes

Prefixed order column with table name to avoid ambiguous SQL query. Also updated the deprecated finders to Rails 4 syntax. Both changes are backwards compatible with Rails 3.