openmrs/openmrs-contrib-id — pull request #15 by Plypy (2014-07-28 10:02:33+00:00)
Title: fix ID-51, groups relation now will be automatically handled in middlewa...

Fixed ID-51, now we'll use the middleware to automatically update(add/delete) the groups relation.

That means, the `User#addGroupsAndSave()` can be deprecated now.

Also I added a `skipLDAP` attribute in Group model for consistency. Actually it's not good to add this kind of temporary flag into `Schema`. But if I don't implement it this way, I will lost the `skipLDAP` after calling constructor.

e.g.
Tihs works,
```javascript
var blah = {
//blahblah
};
user = new User(blah);
user.skipLDAP = true;
```
This doesn't,
```javascript
var blah = {
skipLDAP: true,
//blahblah
};
user = new User(blah);
```

Anyway, not a big deal.