Revision 733f013d

b/snf-astakos-app/astakos/api/projects.py
380 380
        owner = user
381 381
    else:
382 382
        try:
383
            owner = AstakosUser.objects.get(uuid=uuid, email_verified=True)
383
            owner = AstakosUser.objects.accepted().get(uuid=uuid)
384 384
        except AstakosUser.DoesNotExist:
385 385
            raise faults.BadRequest("User does not exist.")
386 386

  
b/snf-astakos-app/astakos/im/forms.py
885 885
        q = self.cleaned_data.get('q') or ''
886 886
        users = q.split(',')
887 887
        users = list(u.strip() for u in users if u)
888
        db_entries = AstakosUser.objects.verified().filter(email__in=users)
888
        db_entries = AstakosUser.objects.accepted().filter(email__in=users)
889 889
        unknown = list(set(users) - set(u.email for u in db_entries))
890 890
        if unknown:
891 891
            raise forms.ValidationError(
b/snf-astakos-app/astakos/im/functions.py
505 505

  
506 506
def enroll_member_by_email(project_id, email, request_user=None, reason=None):
507 507
    try:
508
        user = AstakosUser.objects.verified().get(email=email)
508
        user = AstakosUser.objects.accepted().get(email=email)
509 509
        return enroll_member(project_id, user, request_user, reason=reason)
510 510
    except AstakosUser.DoesNotExist:
511
        raise ProjectConflict(astakos_messages.UNKNOWN_USERS)
511
        raise ProjectConflict(astakos_messages.UNKNOWN_USERS % email)
512 512

  
513 513

  
514 514
def enroll_member(project_id, user, request_user=None, reason=None):
b/snf-astakos-app/astakos/im/management/commands/user-modify.py
332 332

  
333 333
        set_base_quota = options.get('set_base_quota')
334 334
        if set_base_quota is not None:
335
            if not user.is_accepted():
336
                m = "%s is not an accepted user." % user
337
                raise CommandError(m)
335 338
            resource, capacity = set_base_quota
336 339
            self.set_limits([user], resource, capacity, force)
337 340

  

Also available in: Unified diff