added stuff
Change filter_groups methods in controller to the model. Refactor
sorting methods so that it uses sql query
Refactor code from Group index. Took out logic and moved it to the
model. Added counter_cache to make queury faster
Refactor group sort methods. Changed method names to reflect more
closely of what they do
Merge branch 'counter_membership' into improve_group_function

Conflicts:
	app/controllers/groups_controller.rb
	app/models/group.rb