REGISTRAR: allow to check for similar users when no appId is known
RPC: support for checking similar users based on latest application
GUI: check for similar users by latest application

- also return rich users to display better data
- updated messages
REGISTRAR: fixed SQL in check for similar users
GUI: better display of results when checking for similar users
REGISTRAR: better sorting of applications to show latest first
GUI: better sorting of applications to show latest first
Merge pull request #429 from zlamalp/similar

REGISTRAR,GUI: improved UX when searching for similar users
REGISTRAR: base for user mail invitation support

- Added new notification type.
- Added empty methods (authz only) for sending an invitation.
- Added check and creation of required attribute.
REGISTRAR, RPC: added implementation of invitation notifications

Implemented sendInvitation() method.

- Invitation to VO or Group checks for membership and offers linked
  application forms (VO->Group).
- Invitation can be posted to existing user or to email address.
- Language for user is taken from his preference, if not set, from VO/group setting.
- Language for unknown person is manually selected or taken from VO/group setting.
- From address is same as for other notifications.

Fixed link replacements for applications to Groups.

Source formatting.

Added method sendInvitation() to RPC.
GUI: testing support for user invitations

- New notification template can be created from GUI.
- Added appropriate help.
- Added callback to invite user, candidate or unknown.
- Invite unknown user from VO overview.
- Invite known user from Add member tab.
GUI,REGISTRAR: fixed bugs on invitations

- Correctly replace invitation links.
- Use mail subject as subject.
- Allow to invite known/unknown users into VO/Group from GUI.
  Button is on VO Overview / Group members and also when
  adding existing member you can use invite instead of add.
REGISTRAR: Allow to use custom Application URLs for invitations.
Merge pull request #416 from zlamalp/invite

REGISTRAR, GUI: support for inviting users to VO/group
REGISTRAR: check for member by user only if not null

- Skip checking for member by user when user is null
  when auto-approving application to group.
- Source format.
Merge pull request #437 from zlamalp/quickfix

REGISTRAR: check for member by user only if not null