beginning to refactor validity range of dag_links.

We do not use acts_as_paranoid_dag anymore, since there are issues regarding the count attribute that may cause the database to break, which we have referred to as 'dag link error'.
Instead we first try to implement a validity range using scopes, which will have nothing to do with the destroy method.
refactoring validity range on dag links.
Merge branch 'master' into sf/validity_range
adding basic UserGroupMembershipMixins::ValidityRange.
beginning to implement a validity range for indirect memberships.
finishing code and specs for UserGroupMembershipMixins::ValidityRangeForIndirectMemberships.
validity range: clean up basic UserGroupMembership model and specs.
validity range: beginning to refactor Group model by moving the membership methods to a mixin.
validity range: trying to convert the Group methods associating memberships to real active record associations.

This possibliy breaks the UserGroupMembership default scope.
validity range: continuously refactoring Group model.

The associations, in fact, do respect the default scopes. The recent problem had been caused by the dag link structure not considering the membership scopes, i.e. child_users does not consider whether memberships are invalidated.

This is the reason why everything should be done using Group#members and Group#direct_members rather than Group#child_users.
validity range: finishing refactoring of the Group model.
validity range: validity ranges of indirect memberships are now copied to the database in order to use them in scopes.
validity range: fixing failing StatusGroupMembership specs.
validity range: refactoring the User model to match.
validity range: trying to fix failing specs
Merge branch 'master' into sf/validity_range
validity range: fixing models and model specs.
validity range: beginning to refactor controllers and views to match the new interface.
fixing status group recognition.
validity range: trying to trace the recalculation issues of the validity range of indirect memberships while trying to fix the corporate vita.

Apparently the recalculation is called several times, but the last one does not take all neccessary direct memberships into account.