'Verify that name is unique in ALIAS_MODEL.'

def clean(self):

    super(GroupBase, self).clean()
    query = self.ALIAS_MODEL.objects.filter(name=self.name)
    if self.pk:
        query = query.exclude(alias=self)
    if query.exists():
        raise ValidationError({'name': _('This    name    already    exists.')})
    return self.name
