add missing support for the :group ar_options

when showing pagination - all records we have to use the length method so that
we get the size of the array ( for group we would get a hash with counts)
Revert "change how relations are detect so that it can work with relation proxies (aka octopus)"

This reverts commit 584e24023bb6aefd5bc4ec130e8b2658d54661e0.
Merge branch 'kabturek' into rails3
3.4.10