prefix table name on scopes

same as https://github.com/spree/spree/pull/4225, for 2-0-stable/rails 3